Skip to content

Commit

Permalink
fix: 別アカウントで開いたときに異なるアカウントで表示されてしまうのを修正(shiosyakeyakini-info#683)
Browse files Browse the repository at this point in the history
  • Loading branch information
4ster1sk committed Nov 21, 2024
1 parent 16f97d8 commit 0dc23bf
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions lib/state_notifier/common/misskey_notes/misskey_note_notifier.dart
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,21 @@ class MisskeyNoteNotifier extends _$MisskeyNoteNotifier {
);

if (selectedAccount == null) return;
if (user.host == null) {
switch (user) {
case UserLite():
user = user.copyWith(host: accountContext.getAccount.host);

case UserDetailedNotMe():
user = user.copyWith(host: accountContext.getAccount.host);

case UserDetailedNotMeWithRelations():
user = user.copyWith(host: accountContext.getAccount.host);

case MeDetailed():
user = user.copyWith(host: accountContext.getAccount.host);
}
}
await navigateToUserPage(user, account: selectedAccount);
}
}

0 comments on commit 0dc23bf

Please sign in to comment.