fix lint errors

This commit is contained in:
syuilo
2021-11-12 10:52:10 +09:00
parent 84df0714d8
commit b9eaf906e7
22 changed files with 55 additions and 49 deletions

View File

@@ -7,7 +7,7 @@ import { MoreThan, Not, IsNull } from 'typeorm';
const logger = queueLogger.createSubLogger('clean-remote-files');
export default async function cleanRemoteFiles(job: Bull.Job<{}>, done: any): Promise<void> {
export default async function cleanRemoteFiles(job: Bull.Job<Record<string, unknown>>, done: any): Promise<void> {
logger.info(`Deleting cached remote files...`);
let deletedCount = 0;

View File

@@ -3,9 +3,9 @@ import { resyncCharts } from './resync-charts';
const jobs = {
resyncCharts,
} as Record<string, Bull.ProcessCallbackFunction<{}> | Bull.ProcessPromiseFunction<{}>>;
} as Record<string, Bull.ProcessCallbackFunction<Record<string, unknown>> | Bull.ProcessPromiseFunction<Record<string, unknown>>>;
export default function(dbQueue: Bull.Queue<{}>) {
export default function(dbQueue: Bull.Queue<Record<string, unknown>>) {
for (const [k, v] of Object.entries(jobs)) {
dbQueue.process(k, v);
}

View File

@@ -5,7 +5,7 @@ import { driveChart, notesChart, usersChart } from '@/services/chart/index';
const logger = queueLogger.createSubLogger('resync-charts');
export default async function resyncCharts(job: Bull.Job<{}>, done: any): Promise<void> {
export async function resyncCharts(job: Bull.Job<Record<string, unknown>>, done: any): Promise<void> {
logger.info(`Resync charts...`);
// TODO: ユーザーごとのチャートも更新する