[Mapbender-commits] r1042 - trunk/mapbender/http/javascripts

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Thu Jan 25 08:21:33 EST 2007


Author: christoph
Date: 2007-01-25 08:21:33 -0500 (Thu, 25 Jan 2007)
New Revision: 1042

Modified:
   trunk/mapbender/http/javascripts/geometry.js
Log:
fixed bug: last node has been added twice previously

Modified: trunk/mapbender/http/javascripts/geometry.js
===================================================================
--- trunk/mapbender/http/javascripts/geometry.js	2007-01-25 12:22:15 UTC (rev 1041)
+++ trunk/mapbender/http/javascripts/geometry.js	2007-01-25 13:21:33 UTC (rev 1042)
@@ -285,7 +285,11 @@
 	this.close = function(){
 		this.complete = true;
 		if (this.geomtype == geomTypePolygon){
-			if (this.count() > 0){this.addPoint(this.get(0));}
+			if (this.count() > 0){
+				if (!this.get(0).equals(this.get(-1))) {
+					this.addPoint(this.get(0));
+				}
+			}
 		}
 	}
 	



More information about the Mapbender_commits mailing list