fix: code review
This commit is contained in:
parent
997e34ed8a
commit
e4b4bf9900
|
@ -61,7 +61,6 @@ proc addContact*(self: ContactModel, id: string, localNickname: string): string
|
|||
)
|
||||
|
||||
let updating = contact.systemTags.contains(":contact/added")
|
||||
echo "C"
|
||||
if not updating:
|
||||
contact.systemTags.add(":contact/added")
|
||||
let nickname =
|
||||
|
@ -73,6 +72,7 @@ proc addContact*(self: ContactModel, id: string, localNickname: string): string
|
|||
localNickname
|
||||
result = status_contacts.saveContact(contact.id, contact.ensVerified, contact.ensName, contact.ensVerifiedAt, contact.ensVerificationRetries, contact.alias, contact.identicon, contact.systemTags, nickname)
|
||||
self.events.emit("contactAdded", Args())
|
||||
discard requestContactUpdate(contact.id)
|
||||
if updating:
|
||||
let profile = Profile(
|
||||
id: contact.id,
|
||||
|
|
|
@ -40,6 +40,5 @@ proc saveContact*(id: string, ensVerified: bool, ensName: string, ensVerifiedAt:
|
|||
}]
|
||||
callPrivateRPC("saveContact".prefix, payload)
|
||||
|
||||
proc requestContactUpdate*(): string =
|
||||
let publicKey = $getSetting[string](Setting.PublicKey, "")
|
||||
proc requestContactUpdate*(publicKey: string): string =
|
||||
callPrivateRPC("sendContactUpdate".prefix, %* [publicKey, "", ""])
|
Loading…
Reference in New Issue