From 17b2aa77f2e2fdb564bbda727bb527ea380ac17d Mon Sep 17 00:00:00 2001 From: dillonstreator Date: Wed, 21 Feb 2024 19:33:36 -0600 Subject: [PATCH] any -> unknown --- src/processor.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/processor.ts b/src/processor.ts index 16b8f42..4951c04 100644 --- a/src/processor.ts +++ b/src/processor.ts @@ -5,14 +5,14 @@ import { sleep } from "./sleep"; type TxOBEventHandlerResult = { processed_at?: Date; - errors?: { error: any; timestamp: Date }[]; + errors?: { error: unknown; timestamp: Date }[]; }; export type TxOBEvent = { id: string; timestamp: Date; type: TxOBEventType; - data: Record; + data: Record; correlation_id: string; handler_results: Record; errors: number; @@ -256,10 +256,10 @@ export const processEvents = async ( }; export interface Logger { - debug(message?: any, ...optionalParams: any[]): void; - info(message?: any, ...optionalParams: any[]): void; - warn(message?: any, ...optionalParams: any[]): void; - error(message?: any, ...optionalParams: any[]): void; + debug(message?: unknown, ...optionalParams: unknown[]): void; + info(message?: unknown, ...optionalParams: unknown[]): void; + warn(message?: unknown, ...optionalParams: unknown[]): void; + error(message?: unknown, ...optionalParams: unknown[]): void; } export const EventProcessor = ( @@ -310,7 +310,7 @@ export const Processor = ( state = "started"; opts?.logger?.debug("processor started"); - let abortListener: ((this: AbortSignal, ev: Event) => any) | null = null; + let abortListener: ((this: AbortSignal, ev: Event) => unknown) | null = null; (async () => { while (true) {