aboutsummaryrefslogtreecommitdiffstats
path: root/src/Angular.js
diff options
context:
space:
mode:
authorIgor Minar2012-06-08 11:53:17 -0700
committerIgor Minar2012-06-08 15:27:04 -0700
commit5c95b8cccc0d72f7ca3afb1162b9528c1222eb3c (patch)
tree0f4f296e5f2d1ebe5c2864f3874e613458ad6151 /src/Angular.js
parent9be82d942fc6ab2772197c84a35a4c374c604cbc (diff)
downloadangular.js-5c95b8cccc0d72f7ca3afb1162b9528c1222eb3c.tar.bz2
fix(startingTag): make tag name always lowercase
some browsers (IE) always provide the nodeName as upper-case
Diffstat (limited to 'src/Angular.js')
-rw-r--r--src/Angular.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Angular.js b/src/Angular.js
index 20f2e722..c3b57c10 100644
--- a/src/Angular.js
+++ b/src/Angular.js
@@ -755,7 +755,9 @@ function startingTag(element) {
// are not allowed to have children. So we just ignore it.
element.html('');
} catch(e) {}
- return jqLite('<div>').append(element).html().match(/^(<[^>]+>)/)[1];
+ return jqLite('<div>').append(element).html().
+ match(/^(<[^>]+>)/)[1].
+ replace(/^<([\w\-]+)/, function(match, nodeName) { return '<' + lowercase(nodeName); });
}