mirror of
https://github.com/aljazceru/ditto.git
synced 2026-01-29 18:14:23 +01:00
Delete event.ts, use nostr-tools types
This commit is contained in:
@@ -1,10 +1,8 @@
|
||||
import { Conf } from '@/config.ts';
|
||||
import { finishEvent, nip19 } from '@/deps.ts';
|
||||
|
||||
import type { EventTemplate, SignedEvent } from '@/event.ts';
|
||||
import { type Event, type EventTemplate, finishEvent, nip19 } from '@/deps.ts';
|
||||
|
||||
// deno-lint-ignore require-await
|
||||
async function signAdminEvent<K extends number = number>(event: EventTemplate<K>): Promise<SignedEvent<K>> {
|
||||
async function signAdminEvent<K extends number = number>(event: EventTemplate<K>): Promise<Event<K>> {
|
||||
if (!Conf.nsec) throw new Error('No secret key. Set one with DITTO_NSEC.');
|
||||
|
||||
const result = nip19.decode(Conf.nsec);
|
||||
|
||||
Reference in New Issue
Block a user