mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-12-03 11:41:44 +00:00
Added eachAsync options for concurrency
This commit is contained in:
Vendored
+6
-1
@@ -469,6 +469,11 @@ declare module "mongoose" {
|
||||
static Messages: Object;
|
||||
}
|
||||
|
||||
interface EachAsyncOptions {
|
||||
/** defaults to 1 */
|
||||
parallel?: number;
|
||||
}
|
||||
|
||||
/*
|
||||
* section querycursor.js
|
||||
* http://mongoosejs.com/docs/api.html#querycursor-js
|
||||
@@ -502,7 +507,7 @@ declare module "mongoose" {
|
||||
* Returns a promise that resolves when done.
|
||||
* @param callback executed when all docs have been processed
|
||||
*/
|
||||
eachAsync(fn: (doc: T) => any, callback?: (err: any) => void): Promise<T>;
|
||||
eachAsync(fn: (doc: T) => any, options: EachAsyncOptions, callback?: (err: any) => void): Promise<T>;
|
||||
|
||||
/**
|
||||
* Registers a transform function which subsequently maps documents retrieved
|
||||
|
||||
Reference in New Issue
Block a user