From dd66645bb678d47aed2ebcfd0bf1e707253109de Mon Sep 17 00:00:00 2001 From: Natsumi Date: Thu, 26 May 2022 06:10:35 +1200 Subject: [PATCH] Check for friend/unfriend faster at startup --- html/src/app.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/html/src/app.js b/html/src/app.js index 300e65cf..85199eef 100644 --- a/html/src/app.js +++ b/html/src/app.js @@ -10790,12 +10790,16 @@ speechSynthesis.getVoices(); this.friendLogTable.data = await database.getFriendLogHistory(); await API.refreshFriends(); this.friendLogInitStatus = true; + // check for friend/name/rank change AFTER friendLogInitStatus is set for (var friend of friendLogCurrentArray) { var ref = API.cachedUsers.get(friend.userId); if (typeof ref !== 'undefined') { this.updateFriendship(ref); } } + if (typeof API.currentUser.friends !== 'undefined') { + this.updateFriendships(API.currentUser); + } }; $app.methods.addFriendship = function (id) { @@ -12524,7 +12528,7 @@ speechSynthesis.getVoices(); $app.methods.promptChangeWorldYouTubePreview = function (world) { this.$prompt( - 'Enter world YouTube preview, WARNING: once a preview is added it cannot be removed', + 'Enter world YouTube preview', 'Change YouTube Preview', { distinguishCancelAndClose: true,