manageDebug() fix
authorDarren <darren@darrenwhitlen.com>
Fri, 16 Sep 2011 13:37:51 +0000 (14:37 +0100)
committerDarren <darren@darrenwhitlen.com>
Fri, 16 Sep 2011 13:37:51 +0000 (14:37 +0100)
js/util.js

index edbc4853f7d58d9b2fa76499da823989218a9834..4ee8571ad8ec7b06f74eadf28a05a8a1e79ef631 100644 (file)
@@ -11,10 +11,10 @@ function manageDebug(debug) {
     var log, consoleBackUp;
     if (window.console) {  
         consoleBackUp = window.console.log;  
-        window.console.log = function (str) {  
+        window.console.log = function () {  
             if (debug) {  
-                consoleBackUp.call(this, str);  
-            }  
+                consoleBackUp.apply(console, arguments); 
+            }
         };  
     } else {  
         log = window.opera ? window.opera.postError : alert;