[Mapbender-commits] r6620 - trunk/mapbender/http/classes
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Fri Jul 23 05:42:46 EDT 2010
Author: kmq
Date: 2010-07-23 09:42:46 +0000 (Fri, 23 Jul 2010)
New Revision: 6620
Modified:
trunk/mapbender/http/classes/class_group.php
Log:
modify the cnage function of the group Class to check for existance of keys rather than their falsity
Modified: trunk/mapbender/http/classes/class_group.php
===================================================================
--- trunk/mapbender/http/classes/class_group.php 2010-07-23 09:37:21 UTC (rev 6619)
+++ trunk/mapbender/http/classes/class_group.php 2010-07-23 09:42:46 UTC (rev 6620)
@@ -145,20 +145,20 @@
public function change($changes) {
//FIXME: validate input
- $this->name = $changes->name ? $changes->name : $this->name;
- $this->owner = $changes->owner ? $changes->owner : $this->owner;
- $this->description = $changes->description ? $changes->description : $this->description;
- $this->id = $changes->id ? $changes->id : $this->id;
- $this->title = $changes->title ? $changes->title : $this->title;
- $this->address = $changes->address ? $changes->address : $this->address;
- $this->postcode = $changes->postcode ? $changes->postcode : $this->postcode;
- $this->city = $changes->city ? $changes->city : $this->city;
- $this->stateorprovince = $changes->stateorprovince ? $changes->stateorprovince : $this->stateorprovince;
- $this->country = $changes->country ? $changes->country : $this->country;
- $this->voicetelephone = $changes->voicetelephone ? $changes->voicetelephone : $this->voicetelephone;
- $this->facsimiletelephone = $changes->facsimiletelephone ? $changes->facsimiletelephone : $this->facsimiletelephone;
- $this->email = $changes->email ? $changes->email : $this->email;
- $this->logo_path = $changes->logo_path ? $changes->logo_path : $this->logo_path;
+ $this->name = isset($changes->name) ? $changes->name : $this->name;
+ $this->owner = isset($changes->owner) ? $changes->owner : $this->owner;
+ $this->description = isset($changes->description) ? $changes->description : $this->description;
+ $this->id = isset($changes->id) ? $changes->id : $this->id;
+ $this->title = isset($changes->title) ? $changes->title : $this->title;
+ $this->address = isset($changes->address) ? $changes->address : $this->address;
+ $this->postcode = isset($changes->postcode) ? $changes->postcode : $this->postcode;
+ $this->city = isset($changes->city) ? $changes->city : $this->city;
+ $this->stateorprovince = isset($changes->stateorprovince) ? $changes->stateorprovince : $this->stateorprovince;
+ $this->country = isset($changes->country) ? $changes->country : $this->country;
+ $this->voicetelephone = isset($changes->voicetelephone) ? $changes->voicetelephone : $this->voicetelephone;
+ $this->facsimiletelephone = isset($changes->facsimiletelephone) ? $changes->facsimiletelephone : $this->facsimiletelephone;
+ $this->email = isset($changes->email) ? $changes->email : $this->email;
+ $this->logo_path = isset($changes->logo_path) ? $changes->logo_path : $this->logo_path;
return true;
}
More information about the Mapbender_commits
mailing list