You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by bh...@apache.org on 2013/11/14 21:41:16 UTC
git commit: CB-5364 config_parser - check for null element text
Updated Branches:
refs/heads/master 19513a1c3 -> 133836739
CB-5364 config_parser - check for null element text
Project: http://git-wip-us.apache.org/repos/asf/cordova-cli/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-cli/commit/13383673
Tree: http://git-wip-us.apache.org/repos/asf/cordova-cli/tree/13383673
Diff: http://git-wip-us.apache.org/repos/asf/cordova-cli/diff/13383673
Branch: refs/heads/master
Commit: 133836739c9f19de7a9e4dc8074dc0341fa8939c
Parents: 19513a1
Author: Bryan Higgins <bh...@blackberry.com>
Authored: Thu Nov 14 15:40:35 2013 -0500
Committer: Bryan Higgins <bh...@blackberry.com>
Committed: Thu Nov 14 15:40:35 2013 -0500
----------------------------------------------------------------------
src/config_parser.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-cli/blob/13383673/src/config_parser.js
----------------------------------------------------------------------
diff --git a/src/config_parser.js b/src/config_parser.js
index 658874d..249a03f 100644
--- a/src/config_parser.js
+++ b/src/config_parser.js
@@ -126,8 +126,8 @@ config_parser.prototype = {
}
function textMatch(elm1, elm2) {
- var text1 = elm1.text.replace(/\s+/, ""),
- text2 = elm2.text.replace(/\s+/, "");
+ var text1 = elm1.text ? elm1.text.replace(/\s+/, "") : "",
+ text2 = elm2.text ? elm2.text.replace(/\s+/, "") : "";
return (text1 === "" || text1 === text2);
}
}