Merge pull request #1279 from CEOsys/master
copy Element children to prevent value modification when validating
This commit is contained in:
commit
6ddb7cdb28
|
@ -1368,7 +1368,9 @@ public class Element extends Base {
|
|||
dest.value = value;
|
||||
if (children != null) {
|
||||
dest.children = new ArrayList<>();
|
||||
dest.children.addAll(children);
|
||||
for (Element child : children) {
|
||||
dest.children.add((Element) child.copy());
|
||||
}
|
||||
} else {
|
||||
dest.children = null;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue