Update status and count immediately after friend request completes

This commit is contained in:
Dean Herbert 2024-11-05 14:53:54 +09:00
parent e064965281
commit 0087270b7e
No known key found for this signature in database
1 changed files with 4 additions and 2 deletions

View File

@ -95,10 +95,12 @@ private void load(IAPIProvider api, INotificationOverlay? notifications)
req.Success += () =>
{
followerCount += status.Value == FriendStatus.None ? 1 : -1;
bool becameFriend = status.Value == FriendStatus.None;
SetValue(followerCount += becameFriend ? 1 : -1);
status.Value = becameFriend ? FriendStatus.NotMutual : FriendStatus.None;
api.UpdateLocalFriends();
updateStatus();
HideLoadingLayer();
};