fix form.attachTo breaking apf parentNode

pull/134/merge
nightwing 2015-09-07 03:51:29 +04:00
rodzic d314dcef04
commit 50550acb3b
1 zmienionych plików z 6 dodań i 2 usunięć

Wyświetl plik

@ -477,8 +477,12 @@ define(function(require, exports, module) {
container.parentNode = htmlNode;
htmlNode = htmlNode.$int;
}
htmlNode.insertBefore(container.$ext, beforeNode || null);
// if we have apf node, make sure apf child-parent links do not get broken
if (htmlNode.host && container.host) {
htmlNode.host.insertBefore(container.host, beforeNode && beforeNode.host);
} else {
htmlNode.insertBefore(container.$ext, beforeNode || null);
}
show();
}