diff --git a/modules/database/src/adapters/mongoose-adapter/MongooseSchema.ts b/modules/database/src/adapters/mongoose-adapter/MongooseSchema.ts index bfdf787d5..fca460bfd 100644 --- a/modules/database/src/adapters/mongoose-adapter/MongooseSchema.ts +++ b/modules/database/src/adapters/mongoose-adapter/MongooseSchema.ts @@ -320,7 +320,7 @@ export class MongooseSchema extends SchemaAdapter> { if (isNil(filter) && !isNil(parsedQuery)) { return null; } - let finalQuery = this.model.findOne(parsedQuery!, options?.select); + let finalQuery = this.model.findOne(filter!, options?.select); if (options?.populate !== undefined && options?.populate !== null) { finalQuery = this.populate(finalQuery, options?.populate); }