Skip to content

Commit

Permalink
devop: add more unicode detections
Browse files Browse the repository at this point in the history
  • Loading branch information
kvhnuke committed Dec 6, 2024
1 parent 6b06a3f commit 3b2bfab
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/extension/src/libs/utils/unicode-detection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const unicodeLiteral = (str: string) => {
return result;
};
export const getRTLOLTLOSafeString = (str: string): string => {
const isrtloltlo = /[\u202E\u200F]/.test(str) || /[\u202D\u200E]/.test(str);
if (isrtloltlo) return unicodeLiteral(str);
const dangerous = /[\u202A-\u202E\u2066-\u2069\u200E\u200F\u061C]/.test(str);
if (dangerous) return unicodeLiteral(str);
return str;
};
6 changes: 3 additions & 3 deletions packages/extension/src/providers/ethereum/networks/maticzk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ const maticOptions: EvmNetworkOptions = {
blockExplorerAddr: 'https://zkevm.polygonscan.com/address/[[address]]',
chainID: '0x44d',
isTestNetwork: false,
currencyName: 'POL',
currencyNameLong: 'Polygon POL',
currencyName: 'ETH',
currencyNameLong: 'Ethereum',
node: 'wss://nodes.mewapi.io/ws/maticzk',
icon,
coingeckoID: 'polygon-ecosystem-token',
coingeckoID: 'ethereum',
coingeckoPlatform: CoingeckoPlatform.MaticZK,
NFTHandler: shNFTHandler,
assetsInfoHandler,
Expand Down

0 comments on commit 3b2bfab

Please sign in to comment.