Skip to content

Commit a4a53b2

Browse files
authored
Disable token bridge route when M0 route is available (#3306)
M0 route is NTT
1 parent 74b5895 commit a4a53b2

File tree

1 file changed

+7
-5
lines changed
  • wormhole-connect/src/routes/sdkv2

1 file changed

+7
-5
lines changed

wormhole-connect/src/routes/sdkv2/route.ts

+7-5
Original file line numberDiff line numberDiff line change
@@ -387,10 +387,12 @@ const isNttSupportedToken = async (
387387
return isSourceTokenSupported && destTokens.length > 0;
388388
};
389389

390-
const [isManualSupported, isAutomaticSupported] = await Promise.all([
391-
checkRouteSupport('ManualNtt'),
392-
checkRouteSupport('AutomaticNtt'),
393-
]);
390+
const [isManualSupported, isAutomaticSupported, isM0Supported] =
391+
await Promise.all([
392+
checkRouteSupport('ManualNtt'),
393+
checkRouteSupport('AutomaticNtt'),
394+
checkRouteSupport('M0AutomaticRoute'),
395+
]);
394396

395-
return isManualSupported || isAutomaticSupported;
397+
return isManualSupported || isAutomaticSupported || isM0Supported;
396398
};

0 commit comments

Comments
 (0)