File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,18 @@ import {
99 trackDuration ,
1010 identify ,
1111} from '@imtbl/metrics' ;
12- import { BrowserProvider } from 'ethers' ;
12+ // eslint-disable-next-line import/no-duplicates
13+ import * as ethers from 'ethers' ;
14+ // eslint-disable-next-line import/no-duplicates
15+ import { BrowserProvider , getAddress } from 'ethers' ;
16+
17+ // This patches a bundler issue where @0xsequence/core expects
18+ // `ethers.getAddress` to exist on the `ethers` namespace, but Parcel
19+ // fails to attach it in a global build. This ensures the function is
20+ // available before any Passport code executes.
21+ if ( typeof ethers === 'object' && ! ethers . getAddress ) {
22+ ( ethers as any ) . getAddress = getAddress ;
23+ }
1324
1425/* eslint-disable no-undef */
1526const scope = 'openid offline_access profile email transact' ;
You can’t perform that action at this time.
0 commit comments