[Mapbender-commits] r5701 - branches/2.6/http/javascripts

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon Mar 1 05:25:27 EST 2010


Author: verenadiewald
Date: 2010-03-01 05:25:26 -0500 (Mon, 01 Mar 2010)
New Revision: 5701

Modified:
   branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php
Log:
check if node is null in function removeChildNodes

Modified: branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php
===================================================================
--- branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php	2010-02-28 20:22:36 UTC (rev 5700)
+++ branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php	2010-03-01 10:25:26 UTC (rev 5701)
@@ -306,10 +306,18 @@
 }
 
 function removeChildNodes(node) {
-	while (node.childNodes.length > 0) {
-	  var childNode = node.firstChild;
-		node.removeChild(childNode);
+	if (node === null) {
+		return;
 	}
+	try {
+		while (node.childNodes.length > 0) {
+		  var childNode = node.firstChild;
+			node.removeChild(childNode);
+		}
+	}
+	catch (exc) {
+		
+	}
 }
 
 /**



More information about the Mapbender_commits mailing list