From b7ff5fe5ed30e8c6df42511701652ea8e4929b9b Mon Sep 17 00:00:00 2001 From: Andreas Frische Date: Mon, 4 Jan 2016 20:47:10 +0100 Subject: [PATCH] underscore.d.ts uniqueId always returns a string _.uniqueId = function(prefix) { var id = ++idCounter + ''; return prefix ? prefix + id : id; }; always returns string --- underscore/underscore.d.ts | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/underscore/underscore.d.ts b/underscore/underscore.d.ts index 8cf98071b..5cbcbb8d2 100644 --- a/underscore/underscore.d.ts +++ b/underscore/underscore.d.ts @@ -1573,12 +1573,7 @@ interface UnderscoreStatic { * @param prefix A prefix string to start the unique ID with. * @return Unique string ID beginning with `prefix`. **/ - uniqueId(prefix: string): string; - - /** - * @see _.uniqueId - **/ - uniqueId(): number; + uniqueId(prefix?: string): string; /** * Escapes a string for insertion into HTML, replacing &, <, >, ", ', and / characters.