@@ -306,11 +306,11 @@ declare module 'mongoose' {
306306 estimatedDocumentCount ( options ?: QueryOptions < T > , callback ?: Callback < number > ) : QueryWithHelpers < number , HydratedDocument < T , TMethodsAndOverrides , TVirtuals > , TQueryHelpers , T > ;
307307
308308 /**
309- * Returns a document with its `_id` if at least one document exists in the database that matches
310- * the given `filter`, and `null` otherwise.
311- */
312- exists ( filter : FilterQuery < T > , callback : Callback < Pick < Document < T > , '_id' > | null > ) : QueryWithHelpers < Pick < Document < T > , '_id' > | null , HydratedDocument < T , TMethodsAndOverrides , TVirtuals > , TQueryHelpers , T > ;
313- exists ( filter : FilterQuery < T > ) : QueryWithHelpers < Pick < Document < T > , '_id' > | null , HydratedDocument < T , TMethodsAndOverrides , TVirtuals > , TQueryHelpers , T > ;
309+ * Returns a document with its `_id` if at least one document exists in the database that matches
310+ * the given `filter`, and `null` otherwise.
311+ */
312+ exists ( filter : FilterQuery < T > , callback : Callback < { _id : InferId < T > } | null > ) : QueryWithHelpers < Pick < Document < T > , '_id' > | null , HydratedDocument < T , TMethodsAndOverrides , TVirtuals > , TQueryHelpers , T > ;
313+ exists ( filter : FilterQuery < T > ) : QueryWithHelpers < { _id : InferId < T > } | null , HydratedDocument < T , TMethodsAndOverrides , TVirtuals > , TQueryHelpers , T > ;
314314
315315 /** Creates a `find` query: gets a list of documents that match `filter`. */
316316 find < ResultDoc = HydratedDocument < T , TMethodsAndOverrides , TVirtuals > > (
0 commit comments