Skip to content
This repository was archived by the owner on Jan 8, 2022. It is now read-only.

Commit ba79898

Browse files
kyranetiCrawl
authored andcommitted
fix: accumulator's type is T, not any (#9)
🤦🏼‍♂️
1 parent 6c73224 commit ba79898

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ class Collection<K, V> extends Map<K, V> {
368368
* @returns {*}
369369
* @example collection.reduce((acc, guild) => acc + guild.memberCount, 0);
370370
*/
371-
public reduce<T>(fn: (accumulator: any, value: V, key: K, collection: this) => T, initialValue?: T): T {
371+
public reduce<T>(fn: (accumulator: T, value: V, key: K, collection: this) => T, initialValue?: T): T {
372372
let accumulator!: T;
373373

374374
if (typeof initialValue !== 'undefined') {

0 commit comments

Comments
 (0)