From 8b3e19bdf20d1c1158a35d63dbc126670ad434d7 Mon Sep 17 00:00:00 2001 From: wphan Date: Fri, 5 Jan 2024 15:34:32 -0800 Subject: [PATCH] stricter types in tradesPublisher --- src/publishers/tradesPublisher.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/publishers/tradesPublisher.ts b/src/publishers/tradesPublisher.ts index 6d82116..e25e3d4 100644 --- a/src/publishers/tradesPublisher.ts +++ b/src/publishers/tradesPublisher.ts @@ -19,6 +19,8 @@ import { getVariant, ZERO, BN, + OrderActionRecord, + Event, } from '@drift-labs/sdk'; import { logger, setLogLevel } from '../utils/logger'; @@ -130,7 +132,7 @@ const main = async () => { event.eventType === 'OrderActionRecord' && JSON.stringify(event.action) === JSON.stringify(OrderAction.FILL) ), - map((fill) => { + map((fill: Event) => { return { ts: fill.ts.toNumber(), marketIndex: fill.marketIndex,