Skip to content

Commit

Permalink
fix(index.d.ts): add missing Aggregate#skip() & Aggregate#limit()
Browse files Browse the repository at this point in the history
  • Loading branch information
synsh committed Dec 10, 2020
1 parent dd348b1 commit 15d6660
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions index.d.ts
Expand Up @@ -2236,6 +2236,12 @@ declare module "mongoose" {
/** Sets the hint option for the aggregation query (ignored for < 3.6.0) */
hint(value: object | string): this;

/**
* Appends a new $limit operator to this aggregate pipeline.
* @param num maximum number of records to pass to the next stage
*/
limit(num: number): this;

/** Appends new custom $lookup operator to this aggregate pipeline. */
lookup(options: any): this;

Expand Down Expand Up @@ -2265,6 +2271,12 @@ declare module "mongoose" {

/** Sets the session for this aggregation. Useful for [transactions](/docs/transactions.html). */
session(session: mongodb.ClientSession | null): this;

/**
* Appends a new $skip operator to this aggregate pipeline.
* @param num number of records to skip before next stage
*/
skip(num: number): this;

/** Appends a new $sort operator to this aggregate pipeline. */
sort(arg: any): this;
Expand Down

0 comments on commit 15d6660

Please sign in to comment.