This is an automated email from the ASF dual-hosted git repository.
purplecabbage pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-common.git
The following commit(s) were added to refs/heads/master by this push:
new f8cca53 removed rogue console.log that was making lib tests look
fugly, changed CordovaLogger calls to events.emit to match most code. Is
CordovaLogger used anywhere?
f8cca53 is described below
commit f8cca53a4d7f61ad54f2ba5ae584c5787bdd715c
Author: Jesse MacFadyen <[email protected]>
AuthorDate: Wed Dec 6 23:25:45 2017 -0800
removed rogue console.log that was making lib tests look fugly, changed
CordovaLogger calls to events.emit to match most code. Is CordovaLogger used
anywhere?
---
src/ConfigChanges/ConfigChanges.js | 6 +++---
src/ConfigParser/ConfigParser.js | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/ConfigChanges/ConfigChanges.js
b/src/ConfigChanges/ConfigChanges.js
index e0af8a9..1780d25 100644
--- a/src/ConfigChanges/ConfigChanges.js
+++ b/src/ConfigChanges/ConfigChanges.js
@@ -32,7 +32,7 @@
var path = require('path');
var et = require('elementtree');
var ConfigKeeper = require('./ConfigKeeper');
-var CordovaLogger = require('../CordovaLogger');
+var events = require('../events');
var mungeutil = require('./munge-util');
var xml_helpers = require('../util/xml-helpers');
@@ -134,7 +134,7 @@ function add_plugin_changes (pluginInfo, plugin_vars,
is_top_level, should_incre
' cannot be added. <edit-config> changes in this plugin
conflicts with <edit-config> changes in config.xml. Conflicts must be resolved
before plugin can be added.');
}
if (plugin_force) {
- CordovaLogger.get().log(CordovaLogger.WARN, '--force is used.
edit-config will overwrite conflicts if any. Conflicting plugins may not work
as expected.');
+ events.emit('warn', '--force is used. edit-config will overwrite
conflicts if any. Conflicting plugins may not work as expected.');
// remove conflicting munges
var conflict_munge =
mungeutil.decrement_munge(platform_config.config_munge,
isConflictingInfo.conflictingMunge);
@@ -198,7 +198,7 @@ function add_config_changes (config, should_increment) {
}
}
if (Object.keys(isConflictingInfo.conflictingMunge.files).length
!== 0) {
- CordovaLogger.get().log(CordovaLogger.WARN, 'Conflict found,
edit-config changes from config.xml will overwrite plugin.xml changes');
+ events.emit('warn', 'Conflict found, edit-config changes from
config.xml will overwrite plugin.xml changes');
// remove conflicting plugin.xml munges
conflict_munge =
mungeutil.decrement_munge(platform_config.config_munge,
isConflictingInfo.conflictingMunge);
diff --git a/src/ConfigParser/ConfigParser.js b/src/ConfigParser/ConfigParser.js
index 9c3943e..095ccf2 100644
--- a/src/ConfigParser/ConfigParser.js
+++ b/src/ConfigParser/ConfigParser.js
@@ -31,7 +31,7 @@ function ConfigParser (path) {
this.cdvNamespacePrefix = getCordovaNamespacePrefix(this.doc);
et.register_namespace(this.cdvNamespacePrefix,
'http://cordova.apache.org/ns/1.0');
} catch (e) {
- console.error('Parsing ' + path + ' failed');
+ events.emit('error', 'Parsing ' + path + ' failed');
throw e;
}
var r = this.doc.getroot();
--
To stop receiving notification emails like this one, please contact
['"[email protected]" <[email protected]>'].
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]