Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
DylanDylann committed Nov 6, 2024
1 parent 4193bf9 commit 468f6e4
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ function BankConnection({policyID}: BankConnectionStepProps) {
const workspaceAccountID = PolicyUtils.getWorkspaceAccountID(policyID ?? '-1');
const [cardFeeds] = useOnyx(`${ONYXKEYS.COLLECTION.SHARED_NVP_PRIVATE_DOMAIN_MEMBER}${workspaceAccountID}`);
const bankKey = Object.keys(CONST.COMPANY_CARDS.BANKS).find((value) => CONST.COMPANY_CARDS.BANKS[value] === bankName);

Check failure on line 36 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / typecheck

Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{ readonly AMEX: "American Express"; readonly BANK_OF_AMERICA: "Bank of America"; readonly BREX: "Brex"; readonly CAPITAL_ONE: "Capital One"; readonly CHASE: "Chase"; readonly CITI_BANK: "Citibank"; readonly STRIPE: "Stripe"; readonly WELLS_FARGO: "Wells Fargo"; readonly OTHER: "Other"; }'.
const feedName = CONST.COMPANY_CARD.FEED_BANK_NAME[bankKey];
const connectedBank = cardFeeds?.settings?.oAuthAccountDetails?.[feedName] ?? undefined;
const feedName = bankKey ? CONST.COMPANY_CARD.FEED_BANK_NAME?.[bankKey] : undefined;

Check failure on line 37 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / typecheck

Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{ readonly MASTER_CARD: "cdf"; readonly VISA: "vcf"; readonly AMEX: "gl1025"; readonly STRIPE: "stripe"; readonly CITIBANK: "oauth.citibank.com"; readonly CAPITAL_ONE: "oauth.capitalone.com"; ... 4 more ...; readonly AMEX_DIRECT: "oauth.americanexpressfdx.com"; }'.

Check failure on line 37 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / Changed files ESLint check

Unsafe assignment of an `any` value

Check failure on line 37 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / ESLint check

Unsafe assignment of an `any` value
const connectedBank = feedName ? cardFeeds?.settings?.oAuthAccountDetails?.[feedName] : undefined;

Check failure on line 38 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / typecheck

Element implicitly has an 'any' type because expression of type 'any' can't be used to index type 'Record<ValueOf<{ readonly MASTER_CARD: "cdf"; readonly VISA: "vcf"; readonly AMEX: "gl1025"; readonly STRIPE: "stripe"; readonly CITIBANK: "oauth.citibank.com"; readonly CAPITAL_ONE: "oauth.capitalone.com"; ... 4 more ...; readonly AMEX_DIRECT: "oauth.americanexpressfdx.com"; }>, { ...; }>'.

Check failure on line 38 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / Changed files ESLint check

Unsafe assignment of an `any` value

Check failure on line 38 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / Changed files ESLint check

Computed name [feedName] resolves to an `any` value

Check failure on line 38 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / ESLint check

Unsafe assignment of an `any` value

Check failure on line 38 in src/pages/workspace/companyCards/addNew/BankConnection/index.tsx

View workflow job for this annotation

GitHub Actions / ESLint check

Computed name [feedName] resolves to an `any` value

const currentUrl = getCurrentUrl();
const isBankConnectionCompleteRoute = currentUrl.includes(ROUTES.BANK_CONNECTION_COMPLETE);
Expand Down

0 comments on commit 468f6e4

Please sign in to comment.