[mongoose] Modified methods "lean" (#40212)

The type of the returned parameter is determined from Any to T
This commit is contained in:
Joseph
2019-11-07 11:37:59 -08:00
committed by Nathan Shively-Sanders
parent f3a2beb1fd
commit c74f860f8b
+1 -1
View File
@@ -2000,7 +2000,7 @@ declare module "mongoose" {
* getters/setters or other Mongoose magic applied.
* @param {Boolean|Object} bool defaults to true
*/
lean(bool?: boolean | object): Query<any> & QueryHelpers;
lean<T>(bool?: boolean | object): Query<T> & QueryHelpers;
/** Specifies the maximum number of documents the query will return. Cannot be used with distinct() */
limit(val: number): this;