From ac3de292d0e50a7c6b794c9c192310abf8c9bce6 Mon Sep 17 00:00:00 2001 From: ioay Date: Tue, 16 Jan 2024 15:21:22 +0100 Subject: [PATCH] Eslint config: fix require-await rule --- dapp/.eslintrc | 8 -------- dapp/src/components/shared/TokenAmountForm/index.tsx | 5 +---- 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/dapp/.eslintrc b/dapp/.eslintrc index 8d26854f9..091b6b126 100644 --- a/dapp/.eslintrc +++ b/dapp/.eslintrc @@ -41,14 +41,6 @@ "@typescript-eslint/no-floating-promises": "off" } }, - { - "files": [ - "src/components/shared/TokenAmountForm/index.tsx" - ], - "rules": { - "@typescript-eslint/require-await": "off" - } - } ], "settings": { "import/resolver": { diff --git a/dapp/src/components/shared/TokenAmountForm/index.tsx b/dapp/src/components/shared/TokenAmountForm/index.tsx index c4b8dfec7..d8c6fabf0 100644 --- a/dapp/src/components/shared/TokenAmountForm/index.tsx +++ b/dapp/src/components/shared/TokenAmountForm/index.tsx @@ -15,10 +15,7 @@ const TokenAmountForm = withFormik( mapPropsToValues: () => ({ amount: undefined, }), - validate: async ( - { amount }, - { tokenBalance, currency, minTokenAmount }, - ) => { + validate: ({ amount }, { tokenBalance, currency, minTokenAmount }) => { const errors: FormikErrors = {} errors.amount = validateTokenAmount(