Skip to Content

hasEncryptionKey

hasEncryptionKey(address: string, version?: EncryptionKeyVersion): boolean

Defined in: src/react/useEncryption.ts:668 

Checks if an encryption key exists in memory for the given wallet address.

Parameters

ParameterTypeDescription

address

string

Wallet address

version?

EncryptionKeyVersion

When omitted, checks the v3 (current) key — the key write/OPFS/encrypt paths need. Callers that only need to read legacy enc:v2: data should pass "v2" explicitly. (#561 / PR #828)

Returns

boolean

Last updated on