mirror of
https://github.com/nbd-wtf/nostr-tools.git
synced 2025-12-08 16:28:49 +00:00
Rename pubkeys to profiles (NIP-10)
This commit is contained in:
6
nip10.ts
6
nip10.ts
@@ -20,7 +20,7 @@ export type NIP10Result = {
|
||||
/**
|
||||
* List of pubkeys that are involved in the thread in no particular order.
|
||||
*/
|
||||
pubkeys: ProfilePointer[]
|
||||
profiles: ProfilePointer[]
|
||||
}
|
||||
|
||||
export function parse(event: Pick<Event, 'tags'>): NIP10Result {
|
||||
@@ -28,7 +28,7 @@ export function parse(event: Pick<Event, 'tags'>): NIP10Result {
|
||||
reply: undefined,
|
||||
root: undefined,
|
||||
mentions: [],
|
||||
pubkeys: []
|
||||
profiles: []
|
||||
}
|
||||
|
||||
const eTags: string[][] = []
|
||||
@@ -39,7 +39,7 @@ export function parse(event: Pick<Event, 'tags'>): NIP10Result {
|
||||
}
|
||||
|
||||
if (tag[0] === 'p' && tag[1]) {
|
||||
result.pubkeys.push({
|
||||
result.profiles.push({
|
||||
pubkey: tag[1],
|
||||
relays: tag[2] ? [tag[2]] : []
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user