bug: NIP-7 race condition
bug: profile change spam
This commit is contained in:
@ -70,7 +70,6 @@ export type EventBuilderHook = (ev: EventBuilder) => EventBuilder;
|
||||
export class EventPublisher {
|
||||
#pubKey: string;
|
||||
#privateKey?: string;
|
||||
#hasNip07 = "nostr" in window;
|
||||
|
||||
constructor(pubKey: string, privKey?: string) {
|
||||
if (privKey) {
|
||||
@ -81,6 +80,10 @@ export class EventPublisher {
|
||||
}
|
||||
}
|
||||
|
||||
get #hasNip07() {
|
||||
return "nostr" in window;
|
||||
}
|
||||
|
||||
#eb(k: EventKind) {
|
||||
const eb = new EventBuilder();
|
||||
return eb.pubKey(this.#pubKey).kind(k);
|
||||
|
Reference in New Issue
Block a user