Page MenuHomePhabricator

[landing] Fix SIWE after RainbowKit/Wagmi update
ClosedPublic

Authored by ashoat on Feb 14 2023, 2:30 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Nov 21, 5:21 AM
Unknown Object (File)
Thu, Nov 21, 5:21 AM
Unknown Object (File)
Thu, Nov 21, 5:21 AM
Unknown Object (File)
Wed, Nov 20, 4:19 PM
Unknown Object (File)
Nov 10 2024, 6:41 AM
Unknown Object (File)
Nov 10 2024, 6:41 AM
Unknown Object (File)
Nov 10 2024, 6:40 AM
Unknown Object (File)
Nov 5 2024, 2:09 AM
Subscribers

Details

Summary

I'm not sure if this is happening due to the RainbowKit or Wagmi upgrades, but RainbowKit's connectModalOpen is now turning to false a split second before signer is set, which is causing this code to close the modal.

This setTimeout gives us a second to wait and see if signer is set before we decide if the modal closed to the user exiting it or due to a successful wallet auth.

Test Plan

I tested this locally in my dev environment with landing and native both running in dev mode. I tested both X'ing out of the modal (which should trigger this exit condition) and the normal log-in flow (which should NOT trigger)

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable