mirror of
https://github.com/nbd-wtf/nostr-tools.git
synced 2025-12-09 16:48:50 +00:00
nip46: remove "nip44_get_key" method as it was removed from the spec.
This commit is contained in:
6
nip46.ts
6
nip46.ts
@@ -1,4 +1,3 @@
|
|||||||
import { hexToBytes } from '@noble/hashes/utils'
|
|
||||||
import { NostrEvent, UnsignedEvent, VerifiedEvent } from './core.ts'
|
import { NostrEvent, UnsignedEvent, VerifiedEvent } from './core.ts'
|
||||||
import { generateSecretKey, finalizeEvent, getPublicKey, verifyEvent } from './pure.ts'
|
import { generateSecretKey, finalizeEvent, getPublicKey, verifyEvent } from './pure.ts'
|
||||||
import { AbstractSimplePool, SubCloser } from './abstract-pool.ts'
|
import { AbstractSimplePool, SubCloser } from './abstract-pool.ts'
|
||||||
@@ -251,11 +250,6 @@ export class BunkerSigner {
|
|||||||
return await this.sendRequest('nip04_decrypt', [thirdPartyPubkey, ciphertext])
|
return await this.sendRequest('nip04_decrypt', [thirdPartyPubkey, ciphertext])
|
||||||
}
|
}
|
||||||
|
|
||||||
async nip44GetKey(thirdPartyPubkey: string): Promise<Uint8Array> {
|
|
||||||
let resp = await this.sendRequest('nip44_get_key', [thirdPartyPubkey])
|
|
||||||
return hexToBytes(resp)
|
|
||||||
}
|
|
||||||
|
|
||||||
async nip44Encrypt(thirdPartyPubkey: string, plaintext: string): Promise<string> {
|
async nip44Encrypt(thirdPartyPubkey: string, plaintext: string): Promise<string> {
|
||||||
return await this.sendRequest('nip44_encrypt', [thirdPartyPubkey, plaintext])
|
return await this.sendRequest('nip44_encrypt', [thirdPartyPubkey, plaintext])
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"name": "nostr-tools",
|
"name": "nostr-tools",
|
||||||
"version": "2.9.1",
|
"version": "2.9.2",
|
||||||
"description": "Tools for making a Nostr client.",
|
"description": "Tools for making a Nostr client.",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|||||||
Reference in New Issue
Block a user