diff options
Diffstat (limited to 'src/lib/utils.ts')
| -rw-r--r-- | src/lib/utils.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/utils.ts b/src/lib/utils.ts index d3333280..33737b50 100644 --- a/src/lib/utils.ts +++ b/src/lib/utils.ts @@ -11,7 +11,6 @@ import { differenceInMinutes, differenceInSeconds, } from "date-fns"; -import { decrypt } from "nostr-tools/nip49"; import { get as getStore } from "svelte/store"; export function scroll(section: any) { @@ -207,6 +206,7 @@ export const login = async ( cookies.set("token", token, opts); if (u.nsec) { try { + const { decrypt } = await import("nostr-tools/nip49"); cookies.set("sk", bytesToHex(decrypt(u.nsec, user.password)), { ...opts, httpOnly: false, |
