Skip to content

Commit

Permalink
Bugfix provider
Browse files Browse the repository at this point in the history
  • Loading branch information
nigeon committed Oct 26, 2023
1 parent dac86c9 commit 8dba83e
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,14 @@ export class localStorageConnector extends InjectedConnector {
}

async isAuthorized() {
let wallet = await localStorageWallet.getWallet(this.provider as WindowProvider)
const provider = await this.getProvider()
if (!provider) throw new ConnectorNotFoundError()

let wallet = await localStorageWallet.getWallet(provider)
if (!wallet) return false

this.wallet = wallet.account

const provider = await this.getProvider()
if (!provider) throw new ConnectorNotFoundError()
const account = await this.getAccount()
return !!account
}
Expand Down

0 comments on commit 8dba83e

Please sign in to comment.