diff --git a/src/index.ts b/src/index.ts index 733b288..794e7af 100644 --- a/src/index.ts +++ b/src/index.ts @@ -229,11 +229,13 @@ const main = async () => { if (useWebsocket) { subscriptionConfig = { type: 'websocket', + commitment: stateCommitment, }; } else { subscriptionConfig = { type: 'polling', frequency: ORDERBOOK_UPDATE_INTERVAL, + commitment: stateCommitment, }; } diff --git a/src/publishers/dlobPublisher.ts b/src/publishers/dlobPublisher.ts index 1863256..0550c72 100644 --- a/src/publishers/dlobPublisher.ts +++ b/src/publishers/dlobPublisher.ts @@ -126,10 +126,12 @@ const main = async () => { if (useWebsocket) { subscriptionConfig = { type: 'websocket', + commitment: stateCommitment, }; } else { subscriptionConfig = { type: 'polling', + commitment: stateCommitment, frequency: ORDERBOOK_UPDATE_INTERVAL, }; }