incubator-callback-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From purplecabb...@apache.org
Subject [8/9] js commit: Update lib/win8metro/plugin/win8metro/console.js
Date Tue, 14 Aug 2012 23:54:56 GMT
Update lib/win8metro/plugin/win8metro/console.js

Formatting


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/commit/8c9d5410
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/tree/8c9d5410
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/diff/8c9d5410

Branch: refs/heads/master
Commit: 8c9d54107aaf69afcda64d927771374df71669a5
Parents: a55eb34
Author: Jesse MacFadyen <purplecabbage@gmail.com>
Authored: Wed Aug 1 12:27:20 2012 -0700
Committer: Jesse MacFadyen <purplecabbage@gmail.com>
Committed: Wed Aug 1 12:27:20 2012 -0700

----------------------------------------------------------------------
 lib/win8metro/plugin/win8metro/console.js |   26 +++++++----------------
 1 files changed, 8 insertions(+), 18 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/blob/8c9d5410/lib/win8metro/plugin/win8metro/console.js
----------------------------------------------------------------------
diff --git a/lib/win8metro/plugin/win8metro/console.js b/lib/win8metro/plugin/win8metro/console.js
index 89cc56c..a0ada8e 100644
--- a/lib/win8metro/plugin/win8metro/console.js
+++ b/lib/win8metro/plugin/win8metro/console.js
@@ -1,15 +1,11 @@
 
-
 if(!console || !console.log)
 {
-    var exec = require('cordova/exec'),
-        channel = require('cordova/channel');
-    var cordova = require("cordova");
-
+    var exec = require('cordova/exec');
 
     var debugConsole = {
         log:function(msg){
-        exec(null,null,"DebugConsole","log",msg);
+            exec(null,null,"DebugConsole","log",msg);
         },
         warn:function(msg){
             exec(null,null,"DebugConsole","warn",msg);
@@ -19,17 +15,11 @@ if(!console || !console.log)
         }
     };
 
-
     module.exports = debugConsole;
 }
-else
-{
-
-    if(console && console.log)
-    {
-        console.log("console.log exists already!");
-        console.warn = console.warn || function(msg){console.log("warn:"+msg);};
-        console.error = console.error || function(msg){console.log("error:"+msg);};
-
-    }
-}
\ No newline at end of file
+else if(console && console.log) {
+    
+  console.log("console.log exists already!");
+  console.warn = console.warn || function(msg){console.log("warn:"+msg);};
+  console.error = console.error || function(msg){console.log("error:"+msg);};
+}


Mime
View raw message