From 3e28855c0267fc28ad4dca3466285cee1d22049f Mon Sep 17 00:00:00 2001 From: Ana Luiza Ramalho dos Santos Date: Mon, 16 Jan 2023 13:57:39 -0300 Subject: [PATCH] fix: specify type of let Signed-off-by: Ana Luiza Ramalho dos Santos --- .../backend-tasks/src/tasks/PluginTaskSchedulerJanitor.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/backend-tasks/src/tasks/PluginTaskSchedulerJanitor.ts b/packages/backend-tasks/src/tasks/PluginTaskSchedulerJanitor.ts index 4482f2e2bb..0d8ea79d13 100644 --- a/packages/backend-tasks/src/tasks/PluginTaskSchedulerJanitor.ts +++ b/packages/backend-tasks/src/tasks/PluginTaskSchedulerJanitor.ts @@ -53,13 +53,13 @@ export class PluginTaskSchedulerJanitor { private async runOnce() { const dbNull = this.knex.raw('null'); - let tasks = []; + let tasks: Array<{ id: string }>; const configClient = this.knex.client.config.client; if (configClient.includes('sqlite3') || configClient.includes('mysql')) { const now = await this.knex.select(this.knex.fn.now()); tasks = await this.knex(DB_TASKS_TABLE) - .select('*') + .select('id') .where('current_run_expires_at', '<', now); await this.knex(DB_TASKS_TABLE) .where('current_run_expires_at', '<', now)