nostr-tool icon indicating copy to clipboard operation
nostr-tool copied to clipboard

fix: fetch existing kind 0 data if some fields are missing a value for update-metadata

Open 0xtrr opened this issue 1 year ago • 0 comments

As it is now, the update-metadata command will fully overwrite existing kind 0 fields as relays may delete older kind 0 events upon receiving a new one for the same pubkey, as defined in NIP-01. We should probably by default try to fetch the users existing kind 0 data and replace the fields the user specified in the command before publishing the event.

We could also add a flag the user can set to not fetch existing metdata if they want to delete some of the fields.

0xtrr avatar Dec 29 '22 22:12 0xtrr