Skip to content

Commit

Permalink
fix(database): wrong query in mongoose findOne (#1192)
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisPdgn authored Oct 17, 2024
1 parent 5ee40fb commit d527b8a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ export class MongooseSchema extends SchemaAdapter<Model<any>> {
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);
}
Expand Down

0 comments on commit d527b8a

Please sign in to comment.