mirror of
https://github.com/nbd-wtf/nostr-tools.git
synced 2025-12-08 16:28:49 +00:00
fix types, imports and other stuff on nip17 and nip59.
This commit is contained in:
11
nip17.ts
11
nip17.ts
@@ -1,6 +1,6 @@
|
||||
import { PrivateDirectMessage } from './kinds.ts'
|
||||
import { getPublicKey } from './pure'
|
||||
import * as nip59 from './nip59'
|
||||
import { EventTemplate, getPublicKey } from './pure.ts'
|
||||
import * as nip59 from './nip59.ts'
|
||||
|
||||
type Recipient = {
|
||||
publicKey: string
|
||||
@@ -17,10 +17,11 @@ function createEvent(
|
||||
message: string,
|
||||
conversationTitle?: string,
|
||||
replyTo?: ReplyTo,
|
||||
) {
|
||||
const baseEvent = {
|
||||
): EventTemplate {
|
||||
const baseEvent: EventTemplate = {
|
||||
created_at: Math.ceil(Date.now() / 1000),
|
||||
kind: PrivateDirectMessage,
|
||||
tags: [] as (string | string[])[],
|
||||
tags: [],
|
||||
content: message,
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user