Skip to content

Commit

Permalink
Merge pull request #14666 from nick-statsig/master
Browse files Browse the repository at this point in the history
Add $documents pipeline stage and fix $unionWith type
  • Loading branch information
vkarpov15 authored Jun 18, 2024
2 parents e7a6e31 + 40715fe commit 14eebad
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions types/pipelinestage.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ declare module 'mongoose' {
| PipelineStage.CollStats
| PipelineStage.Count
| PipelineStage.Densify
| PipelineStage.Documents

Check failure on line 12 in types/pipelinestage.d.ts

View workflow job for this annotation

GitHub Actions / Lint TS-Files

Trailing spaces not allowed
| PipelineStage.Facet
| PipelineStage.Fill
| PipelineStage.GeoNear
Expand Down Expand Up @@ -93,6 +94,11 @@ declare module 'mongoose' {
}
}

export interface Documents {
/** [`$documents` reference](https://www.mongodb.com/docs/manual/reference/operator/aggregation/documents/) */
$documents: Record<string, Expression>[]
}

export interface Fill {
/** [`$fill` reference](https://www.mongodb.com/docs/manual/reference/operator/aggregation/fill/) */
$fill: {
Expand Down Expand Up @@ -298,6 +304,7 @@ declare module 'mongoose' {
$unionWith:
| string
| { coll: string; pipeline?: Exclude<PipelineStage, PipelineStage.Out | PipelineStage.Merge>[] }
| { coll?: string; pipeline: Exclude<PipelineStage, PipelineStage.Out | PipelineStage.Merge>[] }
}

export interface Unset {
Expand Down

0 comments on commit 14eebad

Please sign in to comment.