cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agri...@apache.org
Subject git commit: Always print full stack trace on uncaught exceptions.
Date Wed, 24 Apr 2013 15:52:26 GMT
Updated Branches:
  refs/heads/master ee696a804 -> a2a5b3f17


Always print full stack trace on uncaught exceptions.

This will allow users to give us useful error info when this happens.


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugman/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugman/commit/a2a5b3f1
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugman/tree/a2a5b3f1
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugman/diff/a2a5b3f1

Branch: refs/heads/master
Commit: a2a5b3f17786ec47e747405dcac6156ac288bfad
Parents: ee696a8
Author: Andrew Grieve <agrieve@chromium.org>
Authored: Wed Apr 24 11:51:49 2013 -0400
Committer: Andrew Grieve <agrieve@chromium.org>
Committed: Wed Apr 24 11:51:49 2013 -0400

----------------------------------------------------------------------
 main.js |    8 +-------
 1 files changed, 1 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugman/blob/a2a5b3f1/main.js
----------------------------------------------------------------------
diff --git a/main.js b/main.js
index fc50c23..8cb2cd4 100755
--- a/main.js
+++ b/main.js
@@ -54,14 +54,8 @@ if (cli_opts.plugins_dir || cli_opts.project) {
         path.join(cli_opts.project, 'cordova', 'plugins');
 }
 
-// only dump stack traces in debug mode, otherwise show error message and exit
-// provide clean output on exceptions rather than dumping a stack trace
 process.on('uncaughtException', function(error){
-    if (cli_opts.debug) {
-        console.error(error.stack);
-    } else {
-        console.error(error + '\n');
-    }
+    console.error(error.stack);
     process.exit(1);
 });
 


Mime
View raw message