From 53b074e8e70acae926d0aa488bb59c69ab7df8ec Mon Sep 17 00:00:00 2001 From: Joel Martin Date: Thu, 16 Aug 2012 13:27:50 -0500 Subject: [PATCH] websock.js: simplify rQshiftStr with apply(). --- include/websock.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/include/websock.js b/include/websock.js index ce4b931..b58e9fd 100644 --- a/include/websock.js +++ b/include/websock.js @@ -129,9 +129,7 @@ function rQshiftStr(len) { if (typeof(len) === 'undefined') { len = rQlen(); } var arr = rQ.slice(rQi, rQi + len); rQi += len; - return arr.map(function (num) { - return String.fromCharCode(num); } ).join(''); - + return String.fromCharCode.apply(null, arr); } function rQshiftBytes(len) { if (typeof(len) === 'undefined') { len = rQlen(); }