From cec116c76fb84896ab24d5b5fb0056aa6044c6c0 Mon Sep 17 00:00:00 2001 From: Kohsuke Kawaguchi Date: Fri, 11 Mar 2011 18:51:19 -0800 Subject: [PATCH] Fragment can contain text and other stuff, not just elements. --- war/src/main/webapp/scripts/hudson-behavior.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/war/src/main/webapp/scripts/hudson-behavior.js b/war/src/main/webapp/scripts/hudson-behavior.js index f5a6aabb95..124bab0c1f 100644 --- a/war/src/main/webapp/scripts/hudson-behavior.js +++ b/war/src/main/webapp/scripts/hudson-behavior.js @@ -439,7 +439,8 @@ function renderOnDemand(e,callback,noBehaviour) { while (c.firstChild!=null) { var n = c.firstChild; e.parentNode.insertBefore(n,e); - noBehaviour || Behaviour.applySubtree(n,true); + if (n.nodeType==1 && !noBehaviour) + Behaviour.applySubtree(n,true); } Element.remove(e); -- GitLab