diff --git a/drift-common b/drift-common index d97d5d7..de78e92 160000 --- a/drift-common +++ b/drift-common @@ -1 +1 @@ -Subproject commit d97d5d7799d8b39aa9a1c5cc79cbb7c9a2f3379c +Subproject commit de78e923d2225db0515c6655335fd3d9a340b6f5 diff --git a/src/dlob-subscriber/DLOBSubscriberIO.ts b/src/dlob-subscriber/DLOBSubscriberIO.ts index 5c726c1..67b2969 100644 --- a/src/dlob-subscriber/DLOBSubscriberIO.ts +++ b/src/dlob-subscriber/DLOBSubscriberIO.ts @@ -186,7 +186,9 @@ export class DLOBSubscriberIO extends DLOBSubscriber { this.driftClient.getMMOracleDataForPerpMarket( marketArgs.marketIndex ), - true + true, + undefined, + new BN(this.slotSource.getSlot()) ); bestBid = @@ -362,7 +364,11 @@ export class DLOBSubscriberIO extends DLOBSubscriber { includeVamm = false; } - const l2 = this.getL2({ ...l2FuncArgs, includeVamm }); + const l2 = this.getL2({ + ...l2FuncArgs, + includeVamm, + latestSlot: new BN(this.slotSource.getSlot()), + }); const { markPrice, bestBidPrice, bestAskPrice, spreadPct, spreadQuote } = COMMON_MATH.calculateSpreadBidAskMark(l2); const slot = l2.slot;