Skip to content

Commit

Permalink
fix: review
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben-Rey committed Nov 14, 2024
1 parent a57072f commit 9456d9f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/snap/snap.manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"url": "https://github.com/massalabs/metamask-massa.git"
},
"source": {
"shasum": "qmk/JDQKFOZrFnN+wx4idmKtYSbR4vR+9y0j0DGmd4g=",
"shasum": "6MkqnZP6kki6xl0X+fVxwk+W7WlEe2/PulNltnecduE=",
"location": {
"npm": {
"filePath": "dist/bundle.js",
Expand Down
4 changes: 2 additions & 2 deletions packages/snap/src/handlers/set-network.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,12 @@ export const setNetwork: Handler<SetNetworkParams, SetNetworkResponse> = async (
});

if (!confirm) {
throw new Error('User denied calling smart contract');
throw new Error('User denied calling network change');
}

await setActiveRPC(network);
await setActiveChainId(node_status.chain_id);
await setActiveMinimalFees(node_status.minimal_fees || DEFAULT_MINIMAL_FEES);
await setActiveMinimalFees(node_status.minimal_fees ?? DEFAULT_MINIMAL_FEES);

return { network: network };
};
2 changes: 1 addition & 1 deletion packages/snap/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ export const onHomePage: OnHomePageHandler = async () => {
*/
export const onUserInput: OnUserInputHandler = async ({ event, id }) => {
assert(event.type === UserInputEventType.ButtonClickEvent);
assert(event.name === 'show-keys-validation' || 'show-keys');
assert(event.name === 'show-keys-validation' || event.name === 'show-keys');

switch (event.name) {
case 'show-keys-validation':
Expand Down

0 comments on commit 9456d9f

Please sign in to comment.