From 9e21911ca3c0c520d624f40560f37e5e8de03a54 Mon Sep 17 00:00:00 2001 From: tschaub Date: Thu, 25 Oct 2012 12:11:25 -0600 Subject: [PATCH] Unnecessary call to appendChild The writeNode function already calls appendChild on the parent. --- lib/OpenLayers/Format/Filter/v1.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/OpenLayers/Format/Filter/v1.js b/lib/OpenLayers/Format/Filter/v1.js index 824984828d..48deb0f9cb 100644 --- a/lib/OpenLayers/Format/Filter/v1.js +++ b/lib/OpenLayers/Format/Filter/v1.js @@ -259,9 +259,8 @@ OpenLayers.Format.Filter.v1 = OpenLayers.Class(OpenLayers.Format.XML, { * {DOMElement} Updated node element. */ writeOgcExpression: function(value, node) { - if(value instanceof OpenLayers.Filter.Function){ - var child = this.writeNode("Function", value, node); - node.appendChild(child); + if (value instanceof OpenLayers.Filter.Function){ + this.writeNode("Function", value, node); } else { this.writeNode("Literal", value, node); }