diff --git a/src/deps.ts b/src/deps.ts index edc893a..5ccdd04 100644 --- a/src/deps.ts +++ b/src/deps.ts @@ -2,5 +2,5 @@ export { type Context, Hono, validator } from 'https://deno.land/x/hono@v3.0.2/m export { cors } from 'https://deno.land/x/hono@v3.0.2/middleware.ts'; export { z } from 'https://deno.land/x/zod@v3.20.5/mod.ts'; export { Author, RelayPool } from 'https://dev.jspm.io/nostr-relaypool@0.5.3'; -export { type Filter, getEventHash, getPublicKey, nip19, signEvent } from 'npm:nostr-tools@^1.7.4'; +export { type Filter, getEventHash, getPublicKey, nip19, signEvent as getSignature } from 'npm:nostr-tools@^1.10.1'; export { default as lmdb } from 'npm:lmdb'; diff --git a/src/publisher.ts b/src/publisher.ts index a152ec1..eaad62e 100644 --- a/src/publisher.ts +++ b/src/publisher.ts @@ -1,4 +1,4 @@ -import { getEventHash, signEvent } from '@/deps.ts'; +import { getEventHash, getSignature } from '@/deps.ts'; import { type Event } from '@/nostr/event.ts'; import { pool } from './client.ts'; @@ -7,7 +7,7 @@ import { publishRelays } from './config.ts'; /** Publish an event to the Nostr relay. */ function publish(event: Event, privatekey: string, relays = publishRelays): void { event.id = getEventHash(event); - event.sig = signEvent(event, privatekey); + event.sig = getSignature(event, privatekey); console.log('Publishing event', event); try { pool.publish(event, relays);