예제 #1
0
 private void UpdatePendingUsers(Action onSuccess = null, Action <Error> onError = null)
 {
     SdkFriendsLogic.Instance.GetPendingUsers(users =>
     {
         Pending = users;
         PendingUsersUpdatedEvent?.Invoke();
         onSuccess?.Invoke();
     }, onError);
 }
예제 #2
0
 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();
     }
 }