proper updating instead of setting things to nil

This commit is contained in:
talksik
2021-12-21 01:49:50 -08:00
parent 9c7fd76644
commit 1f468ca9af
2 changed files with 2 additions and 2 deletions
@@ -101,7 +101,7 @@ class ContactsViewModel : ObservableObject {
}
// setting timestamps to nil to make sure that new server timestamp is set
var userFriend = UserFriends(userId: userId, friendId: friendId, isActive: true, lastUpdatedTimestamp: nil, createdTimestamp: nil)
var userFriend = UserFriends(userId: userId, friendId: friendId, isActive: true, lastUpdatedTimestamp: nil)
self.firestoreService.createOrUpdateUserFriends(userFriend: userFriend) {[weak self] res in
completion(res)