diff --git a/index.d.ts b/index.d.ts index 9b05eca..7a84217 100644 --- a/index.d.ts +++ b/index.d.ts @@ -63,24 +63,18 @@ declare function findLast( handler: ArrayHandler, ): Item | undefined; -declare function findIndex( - collection: Collection, +declare function findIndex( + collection: Item[], handler: ArrayHandler, -): keyof Collection | -1; -declare function findKey< - Item, - Collection extends Record, ->( - collection: Collection, +): number; +declare function findKey( + collection: Record, handler: ObjectHandler, -): keyof Collection | void; -declare function findLastIndex< - Item, - Collection extends Record, ->( - collection: Collection, +): string | void; +declare function findLastIndex( + collection: Item[], handler: ArrayHandler, -): keyof Collection | -1; +): number; declare function forEach( collection: Item[],