Skip to content

Commit df5b888

Browse files
committed
refactor(MongoMemoryServer::stop): remove assertion for typescript types
1 parent 69b1a03 commit df5b888

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

packages/mongodb-memory-server-core/src/MongoMemoryServer.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -482,13 +482,6 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced {
482482
return false;
483483
}
484484

485-
// assert here, otherwise typescript is not happy
486-
// TODO: remove check, typescript does not need this anymore
487-
assertion(
488-
!isNullOrUndefined(this._instanceInfo.instance),
489-
new Error('"instanceInfo.instance" is undefined!')
490-
);
491-
492485
this.debug(
493486
`stop: Stopping MongoDB server on port ${this._instanceInfo.port} with pid ${this._instanceInfo.instance.mongodProcess?.pid}` // "undefined" would say more than ""
494487
);

0 commit comments

Comments
 (0)