Skip to content

Commit 8832c8f

Browse files
committed
docs(utils/async/for-each): add missing type parameters to FactoryFunction
1 parent 68e429f commit 8832c8f

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

  • lib/node_modules/@stdlib/utils/async/for-each/docs/types

lib/node_modules/@stdlib/utils/async/for-each/docs/types/index.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ type Fcn<T, V> = BinaryFcn<T, V> | TernaryFcn<T, V> | QuaternaryFcn<T, V>;
111111
* @param collection - input collection
112112
* @param done - function to invoke upon completion
113113
*/
114-
type FactoryFunction = ( collection: Collection, done: Callback ) => void;
114+
type FactoryFunction<T> = ( collection: Collection<T>, done: Callback ) => void;
115115

116116
/**
117117
* Interface for `forEachAsync`.
@@ -277,7 +277,7 @@ interface ForEachAsync {
277277
* // Run `read` for each element in `files`:
278278
* forEach( files, done );
279279
*/
280-
factory<T = unknown, V = unknown>( options: Options<T, V>, fcn: Fcn<T, V> ): FactoryFunction;
280+
factory<T = unknown, V = unknown>( options: Options<T, V>, fcn: Fcn<T, V> ): FactoryFunction<T>;
281281

282282
/**
283283
* Returns a function to invoke a function once for each element in a collection.
@@ -328,7 +328,7 @@ interface ForEachAsync {
328328
* // Run `read` for each element in `files`:
329329
* forEach( files, done );
330330
*/
331-
factory<T = unknown, V = unknown>( fcn: Fcn<T, V> ): FactoryFunction;
331+
factory<T = unknown, V = unknown>( fcn: Fcn<T, V> ): FactoryFunction<T>;
332332
}
333333

334334
/**

0 commit comments

Comments
 (0)