[Fusionforge-commits] r15282 - in branches/Branch_5_1: . src/common/tracker

Roland Mas lolando at fusionforge.org
Thu Apr 5 15:01:16 CEST 2012


Author: lolando
Date: 2012-04-05 15:01:15 +0200 (Thu, 05 Apr 2012)
New Revision: 15282

Modified:
   branches/Branch_5_1/
   branches/Branch_5_1/src/common/tracker/Artifact.class.php
Log:
Fixed over-enthusiastic optimization: there may be default values to set to extra fields even when migrating an item from a tracker without any extra fields (Evolvis bug #2957)

Modified: branches/Branch_5_1/src/common/tracker/Artifact.class.php
===================================================================
--- branches/Branch_5_1/src/common/tracker/Artifact.class.php	2012-04-04 16:09:26 UTC (rev 15281)
+++ branches/Branch_5_1/src/common/tracker/Artifact.class.php	2012-04-05 13:01:15 UTC (rev 15282)
@@ -1208,15 +1208,16 @@
 				skip it and continue to next item
 
 */
-		if (empty($extra_fields)) {
-			return true;
-		}
 		$update = false;
 
 		//get a list of extra fields for this artifact_type
 		$ef = $this->ArtifactType->getExtraFields();
 		$efk=array_keys($ef);
 
+		if (empty($extra_fields) && empty($ef)) {
+			return true;
+		}
+
 		// If there is a status field, then check against the workflow.
 		for ($i=0; $i<count($efk); $i++) {
 			$efid=$efk[$i];




More information about the Fusionforge-commits mailing list