Skip to content

Commit

Permalink
fix(MongoMemoryServer): add log for when "instance.auth" is "false" b…
Browse files Browse the repository at this point in the history
…ut "opts.auth" is also defined
  • Loading branch information
hasezoey committed May 8, 2023
1 parent ea93afb commit 7463fdc
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/mongodb-memory-server-core/src/MongoMemoryServer.ts
Expand Up @@ -235,6 +235,10 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced {
this.opts = { ...opts };

if (!isNullOrUndefined(this.opts.auth)) {
if (this.opts.instance?.auth === false) {
log('opts.instance.auth is false, but opts.auth was defined!');
}

// assign defaults
this.auth = authDefault(this.opts.auth);
}
Expand Down

0 comments on commit 7463fdc

Please sign in to comment.