From ed9c43f22509ba1bde89a1266c6fcd4561bbd919 Mon Sep 17 00:00:00 2001 From: "James Morris, MS" <96435344+james-a-morris@users.noreply.github.com> Date: Thu, 21 Mar 2024 13:37:40 -0400 Subject: [PATCH] nit(base-adapter): unneeded conditional check (#1312) The `some()` function only returns true if a match is found. An empty array calling `.some` is always guaranteed to return a falsy value. Drive-by comment on my way to getting the Linea Manager --- src/clients/bridges/BaseAdapter.ts | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/clients/bridges/BaseAdapter.ts b/src/clients/bridges/BaseAdapter.ts index fe38758c4..dccbcde6e 100644 --- a/src/clients/bridges/BaseAdapter.ts +++ b/src/clients/bridges/BaseAdapter.ts @@ -276,12 +276,6 @@ export abstract class BaseAdapter { */ isSupportedToken(l1Token: string): l1Token is SupportedL1Token { const relevantSymbols = matchTokenSymbol(l1Token, this.hubChainId); - - // If we don't have a symbol for this token, return that the token is not supported - if (relevantSymbols.length === 0) { - return false; - } - // if the symbol is not in the supported tokens list, it's not supported return relevantSymbols.some((symbol) => this.supportedTokens.includes(symbol)); }