[mongoose] add unwind method with new params type

In mongodb 3.2, the unwind operator can with a object params.
This commit is contained in:
lonsenluo
2017-02-12 17:37:53 +08:00
committed by GitHub
parent a01e02004b
commit fdaff332fb

5
mongoose/index.d.ts vendored
View File

@@ -2163,6 +2163,11 @@ declare module "mongoose" {
* @param fields the field(s) to unwind
*/
unwind(...fields: string[]): this;
/**
* Appends new custom $unwind operator(s) to this aggregate pipeline
* new in mongodb 3.2
*/
unwind(...opts: { path: string, includeArrayIndex?: string, preserveNullAndEmptyArrays?: boolean }[]): this;
}
/*