Skip to content

Commit

Permalink
Merge branch 'master' into feat/update-mm-others
Browse files Browse the repository at this point in the history
  • Loading branch information
hugomrdias authored Sep 7, 2023
2 parents 417c234 + 032f8ba commit 86aa783
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/adapter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ pnpm install filsnap-adapter
This adapter interacts directly with the snap, so Metamask Flask needs to be installed and unlocked in the browser.

```js
import * as Filsnap from 'filsnap-adapter'
import { FilsnapAdapter } from 'filsnap-adapter'

const hasFlask = await Filsnap.hasFlask()
const hasFlask = await FilsnapAdapter.hasFlask()
if (!hasFlask) {
console.error('Flask not installed')
return
}

const snap = await Filsnap.connect({ network: 'testnet' }, 'npm:filsnap')
const snap = await FilsnapAdapter.connect({ network: 'testnet' }, 'npm:filsnap')

const { error, result } = await snap.getAddress()
if (error) {
Expand All @@ -38,7 +38,7 @@ if (error) {
// t1d2xrzcslx7xlbbylc5c3d5lvandqw4iwl6epxba
}

const isConnected = await snap.isConnected()
const isConnected = await FilsnapAdapter.isConnected()
// true
```

Expand Down

0 comments on commit 86aa783

Please sign in to comment.