Skip to content

Commit

Permalink
feat: ensure the snap version in dev and staging env can be compared …
Browse files Browse the repository at this point in the history
…with that in prod (#46)
  • Loading branch information
jonesho authored Dec 20, 2022
1 parent 5b0905a commit 8f89a92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/wallet-ui/src/services/useStarkNetSnap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ export const useStarkNetSnap = () => {
const oldVersionDetected = async () => {
const snaps = await ethereum.request({ method: 'wallet_getSnaps' });
if (typeof snaps[snapId]?.version !== 'undefined') {
return semver.lt(snaps[snapId]?.version, minSnapVersion);
return semver.lt(snaps[snapId]?.version?.split('-')?.[0], minSnapVersion);
}
return false;
};
Expand Down

0 comments on commit 8f89a92

Please sign in to comment.