Showing 1,971 of 13,422 total issues
Avoid too many return
statements within this function. Open
Open
return _.uniq(
EXISTING_BRIDGE_ROUTES[`${fromTokenRouteSymbol}-${fromChainId}`]?.filter(
(value) => value.endsWith(`-${toChainId}`)
)
)
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.chain()
.filter((values, _key) =>
values.some((v) => getTokenAndChainId(v).symbol === toTokenRouteSymbol)
)
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.chain()
.filter((values, key) => {
return (
values.some((v) => {
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.pickBy((values, _key) =>
values.some((token) => token.startsWith(`${toTokenRouteSymbol}-`))
)
.keys()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.pickBy((values, _key) =>
values.some((v) => getTokenAndChainId(v).symbol === toTokenRouteSymbol)
)
.keys()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.chain()
.filter((values, _key) => {
return values.some((v) => {
const { symbol } = getTokenAndChainId(v)
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.pickBy((_values, key) => key.endsWith(`-${fromChainId}`))
.pickBy((values, _key) => {
return _.includes(values, `${toTokenRouteSymbol}-${toChainId}`)
})
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.values()
.flatten()
.map((token) => getTokenAndChainId(token).chainId)
.uniq()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.pickBy((_values, key) => key.startsWith(`${fromTokenRouteSymbol}-`))
.values()
.flatten()
.uniq()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.pickBy((values, _key) =>
values.some((v) => {
return v === `${toTokenRouteSymbol}-${toChainId}`
})
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.entries()
.filter(([key, _values]) => key.endsWith(`-${fromChainId}`))
.map(([_key, values]) => values)
.flatten()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_BRIDGE_ROUTES)
.entries()
.filter(([key, _values]) => key.startsWith(`${fromTokenRouteSymbol}-`))
.filter(([_key, values]) =>
values.some((v) => getTokenAndChainId(v).chainId === toChainId)
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_SWAP_ROUTES)
.chain()
.filter((values, _key) =>
values.some((v) => getTokenAndChainId(v).symbol === toTokenRouteSymbol)
)
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_SWAP_ROUTES)
.mapValues((values) =>
values.filter((token) => token === `${toTokenRouteSymbol}-${toChainId}`)
)
.values()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_SWAP_ROUTES)
.mapValues((values) =>
values.filter((token) => token === `${toTokenRouteSymbol}-${toChainId}`)
)
.pickBy((_values, key) => key.startsWith(`${fromTokenRouteSymbol}-`))
Avoid too many return
statements within this function. Open
Open
if (floatAmount < minimumAmount) return `< ${minimumAmount}`
Avoid too many return
statements within this function. Open
Open
return Intl.NumberFormat(locales, {
minimumSignificantDigits: standardDigits,
maximumSignificantDigits: standardDigits,
}).format(floatAmount)
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_SWAP_ROUTES)
.pickBy((values, _key) => values.some((v) => v.endsWith(`-${toChainId}`)))
.keys()
.filter((key) => key.endsWith(`-${fromChainId}`))
.uniq()
Avoid too many return
statements within this function. Open
Open
return _(EXISTING_SWAP_ROUTES).values().flatten().uniq().value()
Avoid too many return
statements within this function. Open
Open
return EXISTING_SWAP_ROUTES[
`${fromTokenRouteSymbol}-${fromChainId}`
]?.filter((value) => value.endsWith(`-${toChainId}`))