Don't show both realname and username if they are the same

Changelog-Changed: Don't show both realname and username if they are the same
This commit is contained in:
William Casarin
2023-03-14 16:26:52 -06:00
parent af8ce3d32d
commit 04bce34297
12 changed files with 207 additions and 117 deletions

View File

@@ -39,7 +39,7 @@ func reply_desc(profiles: Profiles, event: NostrEvent, locale: Locale = Locale.c
let names: [String] = pubkeys.map {
let prof = profiles.lookup(id: $0)
return Profile.displayName(profile: prof, pubkey: $0)
return Profile.displayName(profile: prof, pubkey: $0).username
}
let uniqueNames = NSOrderedSet(array: names).array as! [String]