Skip to content

Commit

Permalink
Merge pull request #12101 from lpizzinidev/fix-typeerror
Browse files Browse the repository at this point in the history
Solves `syncIndexes` type error on `continueOn Error` option
  • Loading branch information
AbdelrahmanHafez committed Jul 13, 2022
2 parents db1ba6e + a12ccf3 commit e7c6de5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions types/indexes.d.ts
Expand Up @@ -51,8 +51,8 @@ declare module 'mongoose' {
* the model's schema except the `_id` index, and build any indexes that
* are in your schema but not in MongoDB.
*/
syncIndexes(options: mongodb.CreateIndexesOptions | null, callback: Callback<Array<string>>): void;
syncIndexes(options?: mongodb.CreateIndexesOptions): Promise<Array<string>>;
syncIndexes(options: SyncIndexesOptions | null, callback: Callback<Array<string>>): void;
syncIndexes(options?: SyncIndexesOptions): Promise<Array<string>>;
}

interface IndexesDiff {
Expand Down

0 comments on commit e7c6de5

Please sign in to comment.