Skip to content

Commit

Permalink
Merge pull request #43 from liquality/fix-rsk-network-switch
Browse files Browse the repository at this point in the history
fix: compare assets when update injected ethereum for rsk and set to …
  • Loading branch information
bradleySuira authored Jan 23, 2021
2 parents 5ae97a5 + 8a5f701 commit 4effdc4
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "liquality-wallet",
"version": "0.13.1",
"version": "0.13.2",
"private": true,
"license": "MIT",
"author": "Liquality <[email protected]>",
Expand Down
2 changes: 1 addition & 1 deletion src/manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"manifest_version": 2,
"version": "0.13.1",
"version": "0.13.2",
"name": "Liquality Wallet",
"description": "Secure multi-crypto wallet with built-in Atomic Swaps!",
"homepage_url": "https://liquality.io",
Expand Down
11 changes: 11 additions & 0 deletions src/store/migrations.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,17 @@ const migrations = [
}
return { ...state, customTokens }
}
},
{ // Fix for RSK token injected asset
version: 4,
migrate: async (state) => {
if (state.injectEthereumAsset === 'RSK') {
const injectEthereumAsset = 'RBTC'
return { ...state, injectEthereumAsset }
}

return { ...state }
}
}
]

Expand Down
4 changes: 4 additions & 0 deletions src/views/Settings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@ export default {
else this.disableEthereumInjection()
},
updateInjectEthereumAsset (asset) {
// Update back to RBTC as asset
if (asset === 'RSK') {
asset = 'RBTC'
}
this.setEthereumInjectionAsset({ asset })
}
}
Expand Down

0 comments on commit 4effdc4

Please sign in to comment.