diff --git a/package.json b/package.json index d1f6401..e3cdc86 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "paravel", - "version": "0.4.18", + "version": "0.4.19", "description": "Yet another toolkit for nostr", "author": "hodlbod", "license": "MIT", diff --git a/src/util/nostr.ts b/src/util/nostr.ts index c3e7027..63a0cbc 100644 --- a/src/util/nostr.ts +++ b/src/util/nostr.ts @@ -82,7 +82,13 @@ export const hasValidSignature = cached({ return 'invalid' } }, - getValue: ([e]: [Event]) => verifyEvent(e), + getValue: ([e]: [Event]) => { + try { + return verifyEvent(e) + } catch (err) { + return false + } + }, }) // ==========================================================================