From e17111a85943c686b52146971e1fea2782f6d5c5 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Sat, 26 Aug 2023 12:52:24 -0500 Subject: [PATCH] utils/web: PendingEvent --> EventStub --- src/utils/web.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/utils/web.ts b/src/utils/web.ts index 91eaacdc..5df00603 100644 --- a/src/utils/web.ts +++ b/src/utils/web.ts @@ -7,12 +7,12 @@ import { nostrNow } from '@/utils.ts'; import type { AppContext } from '@/app.ts'; /** EventTemplate with or without a timestamp. If no timestamp is given, it will be generated. */ -interface PendingEvent extends Omit, 'created_at'> { +interface EventStub extends Omit, 'created_at'> { created_at?: number; } /** Publish an event through the pipeline. */ -async function createEvent(t: PendingEvent, c: AppContext): Promise> { +async function createEvent(t: EventStub, c: AppContext): Promise> { const pubkey = c.get('pubkey'); if (!pubkey) { @@ -28,7 +28,7 @@ async function createEvent(t: PendingEvent, c: AppContext): } /** Publish an admin event through the pipeline. */ -async function createAdminEvent(t: PendingEvent, c: AppContext): Promise> { +async function createAdminEvent(t: EventStub, c: AppContext): Promise> { const event = await signAdminEvent({ created_at: nostrNow(), ...t,