From a477547c80a5f949e676c384c542ad3c54f8f589 Mon Sep 17 00:00:00 2001 From: notfire Date: Sun, 4 Jan 2026 15:14:19 -0500 Subject: [PATCH] add additional memo check for going to an already loaded user --- src/components/user_profile/user_profile.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/components/user_profile/user_profile.js b/src/components/user_profile/user_profile.js index 1f890f74..05b45884 100644 --- a/src/components/user_profile/user_profile.js +++ b/src/components/user_profile/user_profile.js @@ -145,13 +145,19 @@ const UserProfile = { if (user) { loadById(user.id) this.note = user?.relationship?.note + if (this.note === undefined) { + this.$store.dispatch('fetchUserRelationshipNote', user.id) + .then((resp) => { + this.note = resp + }) + } this.$store.dispatch('setDisplayBackground', user.background_image) } else { this.$store.dispatch('fetchUser', userNameOrId) .then(({ id, relationship, background_image }) => { this.note = relationship?.note if (this.note === undefined) { - this.$store.dispatch('fetchUserRelationshipNote', userNameOrId) + this.$store.dispatch('fetchUserRelationshipNote', user.id) .then((resp) => { this.note = resp })