Skip to content

Commit 923e496

Browse files
durrannbbeeken
andauthored
Update src/cmap/connect.ts
Co-authored-by: Neal Beeken <neal.beeken@mongodb.com>
1 parent 564449c commit 923e496

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/cmap/connect.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -307,9 +307,7 @@ function parseConnectOptions(options: ConnectionOptions): SocketConnectOpts {
307307
(result as Document)[name] = options[name];
308308
}
309309
}
310-
if (result.keepAliveInitialDelay == null) {
311-
result.keepAliveInitialDelay = 120000;
312-
}
310+
result.keepAliveInitialDelay ??= 120000;
313311
result.keepAlive = true;
314312
result.noDelay = options.noDelay ?? true;
315313

0 commit comments

Comments
 (0)