Skip to content

Commit cabdbd2

Browse files
committed
missing check
1 parent bb2607f commit cabdbd2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

v4-client-js/src/clients/composite-client.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,11 @@ export class CompositeClient {
550550
);
551551
const orderTimeInForce = calculateTimeInForce(type, timeInForce, execution, postOnly);
552552
let goodTilBlockTime = 0;
553-
if (orderFlags === OrderFlags.LONG_TERM || orderFlags === OrderFlags.CONDITIONAL) {
553+
if (
554+
orderFlags === OrderFlags.LONG_TERM ||
555+
orderFlags === OrderFlags.CONDITIONAL ||
556+
orderFlags === OrderFlags.TWAP
557+
) {
554558
if (goodTilTimeInSeconds == null) {
555559
throw new Error('goodTilTimeInSeconds must be set for LONG_TERM or CONDITIONAL order');
556560
} else {

0 commit comments

Comments
 (0)