fix: sha512 access

This commit is contained in:
Danish Arora 2025-08-05 11:42:08 +05:30
parent 8b714b61a7
commit 2cdcd567bb
No known key found for this signature in database
GPG Key ID: 1C6EF37CDAE1426E

View File

@ -6,10 +6,13 @@
*/
import * as ed from '@noble/ed25519';
import { sha512 } from '@noble/hashes/sha512';
import { bytesToHex, hexToBytes } from '@/lib/utils';
import { LOCAL_STORAGE_KEYS } from '@/lib/waku/constants';
import { DelegationInfo } from './types';
ed.etc.sha512Sync = (...m) => sha512(ed.etc.concatBytes(...m));
export class KeyDelegation {
private static readonly DEFAULT_EXPIRY_HOURS = 24;