Skip to content

Session restore ignores walletConnect chains/metadata changes #7

@satoshai-dev

Description

@satoshai-dev

Problem

The session restore useEffect only depends on walletConnect?.projectId:

}, [walletConnect?.projectId]);

If the consumer changes chains or metadata without changing projectId, the WalletConnect provider won't be re-initialized with the updated config.

Fix

Add walletConnect?.chains and walletConnect?.metadata to the dependency array, or serialize the full config object for comparison.

Context

Identified during code review of PR #2. Low priority since these props rarely change at runtime.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions