Skip to content

Commit

Permalink
Rel/0.9.2 - fix unsupported chains (#93)
Browse files Browse the repository at this point in the history
* fix unsupported chains bug

* bump version to 0.9.2
  • Loading branch information
mindofmar authored Sep 5, 2023
1 parent 0eaa757 commit fa4389c
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Wallet Guard: Protect Your Crypto",
"version": "0.9.1",
"version": "0.9.2",
"description": "A browser extension for detecting phishing attacks on crypto wallets",
"main": "index.js",
"scripts": {
Expand Down
11 changes: 9 additions & 2 deletions src/lib/simulation/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export type CompletedSuccessfulSimulation = CompletedSimulation & {

// Thank you Pocket Universe for leading the way in proxying transactions
// https://github.com/jqphu/PocketUniverse
export const addSimulation = async (simulation: LoadingSimulation) => {
export const addSimulation = async (simulation: StoredSimulation) => {
const data = await chrome.storage.local.get('simulations');
const simulations: StoredSimulation[] = data.simulations || [];

Expand Down Expand Up @@ -139,7 +139,14 @@ export const fetchSimulationAndUpdate = async (args: TransactionArgs) => {

// Automatically skip if chain id is incorrect. This prevents the popup.
if (!SUPPORTED_CHAINS.includes(args.chainId)) {
return skipSimulation(args.id);
state = StoredSimulationState.Confirmed;

return addSimulation({
id: args.id,
signer: args.signer,
args,
state,
} as StoredSimulation);
}

console.log('args', args);
Expand Down
2 changes: 1 addition & 1 deletion src/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"name": "Wallet Guard: Protect Your Crypto",
"key": "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA0SMGNwLFsP2k1jAD54vtDqLJuIpeZWCc9gdvo2N8hzE1qIkOt29ynU1VgkJbtfuWHqWSyOCo1ljs2MjbqqFjG4qz5o3ZrEAMwmEbWGCuPddUIIiWIK0oF+BkwZiRpRS2nw/i9Dmeusf0eOlxxLYD0NpKszX73lqGt4LBIY8Wva7vmqdnKPa1F6+DDZviXcBRa8CLCzqDujTjON37o+NvQOq2u49UzVXr/DcePFrUTnnjdNkKTQkLlH00lwvxUUJl0g5IVdlxNgZXPY/C6P39YIIxsBFJH0rXvQrLgED6NGR17CBnLhOmmYghku17yoUGg3KrT4aeh8+uG5NrQZuqGwIDAQAB",
"description": "Wallet Guard acts as a security companion to your crypto wallet of choice, so you can browse at ease.",
"version": "0.9.1",
"version": "0.9.2",
"icons": {
"128": "images/wg_logos/logo_128x128.png"
},
Expand Down

0 comments on commit fa4389c

Please sign in to comment.