private void UpdatePendingUsers(Action onSuccess = null, Action <Error> onError = null) { SdkFriendsLogic.Instance.GetPendingUsers(users => { Pending = users; PendingUsersUpdatedEvent?.Invoke(); onSuccess?.Invoke(); }, onError); }
private void RemoveUserFromMemory(FriendModel user) { if (Friends.Contains(user)) { Friends.Remove(user); UserFriendsUpdatedEvent?.Invoke(); } if (Pending.Contains(user)) { Pending.Remove(user); PendingUsersUpdatedEvent?.Invoke(); } if (Requested.Contains(user)) { Requested.Remove(user); RequestedUsersUpdatedEvent?.Invoke(); } if (Blocked.Contains(user)) { Blocked.Remove(user); BlockedUsersUpdatedEvent?.Invoke(); } }