[Fusionforge-commits] r13815 - trunk/src/plugins/oslc/include/oslc-zend/application/controllers

Madhumita Dhar mdhar at fusionforge.org
Tue Jul 19 15:45:10 CEST 2011


Author: mdhar
Date: 2011-07-19 15:45:10 +0200 (Tue, 19 Jul 2011)
New Revision: 13815

Modified:
   trunk/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php
Log:


Modified: trunk/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php
===================================================================
--- trunk/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php	2011-07-18 15:41:56 UTC (rev 13814)
+++ trunk/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php	2011-07-19 13:45:10 UTC (rev 13815)
@@ -602,14 +602,10 @@
 		}
 
 		$at = new ArtifactType($grp, $creation_params['tracker']);
-		if (!$at || !is_object($at)) {
-			throw new Exception('Error: Could Not Get ArtifactType. Please give a valid tracker identifier.', $code);
-		}
+		if ($at->isError())	throw new Exception($at->getErrorMessage());
 
 		$a = new Artifact($at);
-		if (!$a || !is_object($a)) {
-			throw new Exception('Error: Could Not Get Artifact');
-		}
+		if ($a->isError())	throw new Exception($a->getErrorMessage());
 
 		// Check that Mandatory fields are given.
 		if (!isset($cm_request['title'])) {




More information about the Fusionforge-commits mailing list