Skip to content

Commit e052aa1

Browse files
committed
style(MongoInstance::closeHandler): correct parameter types to include "null"
1 parent 0b1d6d1 commit e052aa1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/mongodb-memory-server-core/src/util/MongoInstance.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -499,9 +499,10 @@ export class MongoInstance extends EventEmitter implements ManagerBase {
499499
/**
500500
* Write the CLOSE event to the debug function
501501
* @param code The Exit code to handle
502+
* @param signal The Signal to handle
502503
* @fires MongoInstance#instanceClosed
503504
*/
504-
closeHandler(code: number, signal: string): void {
505+
closeHandler(code: number | null, signal: string | null): void {
505506
// check if the platform is windows, if yes check if the code is not "12" or "0" otherwise just check code is not "0"
506507
// because for mongodb any event on windows (like SIGINT / SIGTERM) will result in an code 12
507508
// https://docs.mongodb.com/manual/reference/exit-codes/#12

0 commit comments

Comments
 (0)