@ -116,15 +116,6 @@ export default function useEventPublisher() {
|
||||
}
|
||||
}
|
||||
},
|
||||
/**
|
||||
* Write to every online relay using Blastr.
|
||||
* https://github.com/MutinyWallet/blastr
|
||||
*/
|
||||
broadcastWithBlastr: (ev: NEvent | undefined) => {
|
||||
if (ev) {
|
||||
System.WriteOnceToRelay("wss://nostr.mutinywallet.com", ev);
|
||||
}
|
||||
},
|
||||
muted: async (keys: HexKey[], priv: HexKey[]) => {
|
||||
if (pubKey) {
|
||||
const ev = NEvent.ForPubKey(pubKey);
|
||||
@ -260,6 +251,18 @@ export default function useEventPublisher() {
|
||||
return await signEvent(ev);
|
||||
}
|
||||
},
|
||||
saveRelays: async () => {
|
||||
if (pubKey) {
|
||||
const ev = NEvent.ForPubKey(pubKey);
|
||||
ev.Kind = EventKind.ContactList;
|
||||
ev.Content = JSON.stringify(relays);
|
||||
for (const pk of follows) {
|
||||
ev.Tags.push(new Tag(["p", pk], ev.Tags.length));
|
||||
}
|
||||
|
||||
return await signEvent(ev);
|
||||
}
|
||||
},
|
||||
saveRelaysSettings: async () => {
|
||||
if (pubKey) {
|
||||
const ev = NEvent.ForPubKey(pubKey);
|
||||
|
Reference in New Issue
Block a user