[Mapbender-commits] r6962 - trunk/mapbender/http/classes
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Wed Sep 29 08:44:53 EDT 2010
Author: christoph
Date: 2010-09-29 12:44:53 +0000 (Wed, 29 Sep 2010)
New Revision: 6962
Modified:
trunk/mapbender/http/classes/class_wmc.php
Log:
throw exception if input parameter not valid
Modified: trunk/mapbender/http/classes/class_wmc.php
===================================================================
--- trunk/mapbender/http/classes/class_wmc.php 2010-09-29 12:43:47 UTC (rev 6961)
+++ trunk/mapbender/http/classes/class_wmc.php 2010-09-29 12:44:53 UTC (rev 6962)
@@ -938,6 +938,9 @@
public function toJavaScript () {
$skipWmsArray = array();
if (func_num_args() === 1) {
+ if (!is_array(func_get_arg(0))) {
+ throw new Exception("Invalid argument, must be array.");
+ }
$skipWmsArray = func_get_arg(0);
}
@@ -1680,6 +1683,13 @@
);
$this->overviewMap->setIsOverview(true);
+ if (is_array($this->generalExtensionArray["OV_SRS"])) {
+ $this->generalExtensionArray["OV_SRS"] = $this->generalExtensionArray["OV_SRS"][0];
+ $this->generalExtensionArray["OV_MINX"] = $this->generalExtensionArray["OV_MINX"][0];
+ $this->generalExtensionArray["OV_MINY"] = $this->generalExtensionArray["OV_MINY"][0];
+ $this->generalExtensionArray["OV_MAXX"] = $this->generalExtensionArray["OV_MAXX"][0];
+ $this->generalExtensionArray["OV_MAXY"] = $this->generalExtensionArray["OV_MAXY"][0];
+ }
$bbox = new Mapbender_bbox($this->generalExtensionArray["OV_MINX"], $this->generalExtensionArray["OV_MINY"], $this->generalExtensionArray["OV_MAXX"], $this->generalExtensionArray["OV_MAXY"], $this->generalExtensionArray["OV_SRS"]);
$this->overviewMap->setExtent($bbox);
}
More information about the Mapbender_commits
mailing list