From b9aa271bfc4ef66c7197ff09069a4dae81ec519a Mon Sep 17 00:00:00 2001 From: Labhansh Agrawal Date: Sun, 28 Mar 2021 21:16:38 +0530 Subject: [PATCH] Fix @typescript-eslint/await-thenable errors --- .eslintrc.json | 1 - app/updater.ts | 4 ++-- test/index.ts | 2 ++ 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 9fe39bdb..03be593b 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -104,7 +104,6 @@ "@typescript-eslint/ban-types": "off", "no-shadow": "off", "@typescript-eslint/no-shadow": ["error"], - "@typescript-eslint/await-thenable": "off", "@typescript-eslint/no-floating-promises": "off", "@typescript-eslint/no-misused-promises": "off", "@typescript-eslint/no-unnecessary-type-assertion": "off", diff --git a/app/updater.ts b/app/updater.ts index 86bfb597..e0f55fbc 100644 --- a/app/updater.ts +++ b/app/updater.ts @@ -29,8 +29,8 @@ async function init() { console.error('Error fetching updates', `${err.message} (${err.stack})`); }); - const config = await retry(async () => { - const content = await getDecoratedConfig(); + const config = await retry(() => { + const content = getDecoratedConfig(); if (!content) { throw new Error('No config content loaded'); diff --git a/test/index.ts b/test/index.ts index ca84dfae..93115916 100644 --- a/test/index.ts +++ b/test/index.ts @@ -1,3 +1,5 @@ +/* eslint-disable eslint-comments/disable-enable-pair */ +/* eslint-disable @typescript-eslint/await-thenable */ // Native import path from 'path'; import fs from 'fs-extra';