[Pkg-javascript-commits] [sockjs-client] 344/434: Change the semantics of info option a bit - extend not overwrite

Tonnerre Lombard tonnerre-guest at moszumanska.debian.org
Wed Jan 8 00:47:24 UTC 2014


This is an automated email from the git hooks/post-receive script.

tonnerre-guest pushed a commit to branch master
in repository sockjs-client.

commit 7637961d055fe4a2ee86212edd509d8f5ccf5e9a
Author: Marek Majkowski <majek04 at gmail.com>
Date:   Fri Feb 10 18:18:21 2012 +0000

    Change the semantics of info option a bit - extend not overwrite
---
 lib/sockjs.js   | 2 +-
 tests/config.js | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/sockjs.js b/lib/sockjs.js
index 6173327..858b9ff 100644
--- a/lib/sockjs.js
+++ b/lib/sockjs.js
@@ -34,7 +34,7 @@ var SockJS = function(url, dep_protocols_whitelist, options) {
         if (info) {
             if (that._options.info) {
                 // Override if user supplies the option
-                info = that._options.info;
+                info = utils.objectExtend(info, that._options.info);
             }
             if (that._options.rtt) {
                 rtt = that._options.rtt;
diff --git a/tests/config.js b/tests/config.js
index f03192b..00fb41e 100644
--- a/tests/config.js
+++ b/tests/config.js
@@ -5,7 +5,8 @@ exports.config = {
         sockjs_opts: {
             devel: true,
             debug: true,
-            info: {websocket:true, cookie_need:false}
+            // websocket:false
+            info: {cookie_needed:false}
         }
     },
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/sockjs-client.git



More information about the Pkg-javascript-commits mailing list