smartxml: fix
authorAleksander Łukasz <aleksander.lukasz@nowoczesnapolska.org.pl>
Tue, 19 Nov 2013 16:30:10 +0000 (17:30 +0100)
committerAleksander Łukasz <aleksander.lukasz@nowoczesnapolska.org.pl>
Tue, 19 Nov 2013 16:30:10 +0000 (17:30 +0100)
TEXT_NODE doesn't inherit from HTMLElement

src/smartxml/smartxml.js

index 637fda6..6609092 100644 (file)
@@ -376,7 +376,7 @@ $.extend(Document.prototype, Backbone.Events, {
     TextNodeFactory: TextNode,
 
     createElementNode: function(from) {
-        if(!(from instanceof HTMLElement)) {
+        if(!(from instanceof Node)) {
             if(from.text) {
                 from = document.createTextNode(from.text);
             } else {