feat: fast zaps
This commit is contained in:
@ -191,7 +191,7 @@ export default function useEventPublisher() {
|
||||
return await signEvent(ev);
|
||||
}
|
||||
},
|
||||
zap: async (author: HexKey, note?: HexKey, msg?: string) => {
|
||||
zap: async (amount: number, author: HexKey, note?: HexKey, msg?: string) => {
|
||||
if (pubKey) {
|
||||
const ev = NEvent.ForPubKey(pubKey);
|
||||
ev.Kind = EventKind.ZapRequest;
|
||||
@ -201,6 +201,7 @@ export default function useEventPublisher() {
|
||||
ev.Tags.push(new Tag(["p", author], ev.Tags.length));
|
||||
const relayTag = ["relays", ...Object.keys(relays)];
|
||||
ev.Tags.push(new Tag(relayTag, ev.Tags.length));
|
||||
ev.Tags.push(new Tag(["amount", amount.toString()], ev.Tags.length));
|
||||
processContent(ev, msg || "");
|
||||
return await signEvent(ev);
|
||||
}
|
||||
|
Reference in New Issue
Block a user