From 730db3556b2fc4cedb54329023334fb66f3203d8 Mon Sep 17 00:00:00 2001 From: ashwinr Date: Tue, 13 Aug 2013 22:54:36 -0400 Subject: [PATCH] hash function callback to _.memoize() can have any number of arguments --- underscore/underscore.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/underscore/underscore.d.ts b/underscore/underscore.d.ts index c67442039..7c92ca007 100644 --- a/underscore/underscore.d.ts +++ b/underscore/underscore.d.ts @@ -860,7 +860,7 @@ declare module _ { **/ export function memoize( fn: Function, - hashFn?: (n: any) => string): Function; + hashFn?: (...n: any[]) => string): Function; /** * Much like setTimeout, invokes function after wait milliseconds. If you pass the optional arguments, @@ -1778,7 +1778,7 @@ declare class _ { * Wrapped type `Function`. * @see _.memoize **/ - memoize(hashFn?: (n: any) => string): Function; + memoize(hashFn?: (...n: any[]) => string): Function; /** * Wrapped type `Function`. @@ -2544,7 +2544,7 @@ interface _Chain { * Wrapped type `Function`. * @see _.memoize **/ - memoize(hashFn?: (n: any) => string): _Chain; + memoize(hashFn?: (...n: any[]) => string): _Chain; /** * Wrapped type `Function`.