[Fusionforge-commits] r9484 - trunk/gforge/common/include

Roland Mas lolando at libremir.placard.fr.eu.org
Wed Apr 14 16:15:25 CEST 2010


Author: lolando
Date: 2010-04-14 16:15:25 +0200 (Wed, 14 Apr 2010)
New Revision: 9484

Modified:
   trunk/gforge/common/include/User.class.php
Log:
Fixed logic error

Modified: trunk/gforge/common/include/User.class.php
===================================================================
--- trunk/gforge/common/include/User.class.php	2010-04-14 14:15:14 UTC (rev 9483)
+++ trunk/gforge/common/include/User.class.php	2010-04-14 14:15:25 UTC (rev 9484)
@@ -1515,7 +1515,7 @@
 		$res = db_query_params ('SELECT role_id FROM user_group WHERE user_id=$1 AND group_id=$2',
 					array ($this->getID(),
 					       $group->getID())) ;
-		if (!$res) {
+		if (!$res || db_numrows($res) < 1) {
 			$this->setError('User::getRole::DB - Could Not get role_id '.db_error());
 			return false;
 		}




More information about the Fusionforge-commits mailing list