forked from science-ation/science-ation
Commit earlier fix to getProject returning invalid project object, im assuming this fixes michaels issue even though i havent heard yet...
This commit is contained in:
parent
c87f23397f
commit
5df66f4b7e
@ -523,6 +523,9 @@ function getProject($userId){
|
||||
return "register_participants.inc.php::getProject -> User not found";
|
||||
}
|
||||
$regId = $result['registrations_id'];
|
||||
if(!$regId) {
|
||||
return "register_participants.inc.php::getProject -> no registration id";
|
||||
}
|
||||
// FIXME - in the future, this should be able to handle a many-to-many
|
||||
// relationship in projects to registrations (so remove that LIMIT 1)
|
||||
$fields = implode(',', array(
|
||||
@ -544,8 +547,11 @@ function getProject($userId){
|
||||
AND projects.conferences_id='".$conference['id']."'
|
||||
LIMIT 1");
|
||||
if(mysql_error()) {
|
||||
return "register_participants.inc.php::getProject -> " . $mysql_error();
|
||||
}else{
|
||||
return "register_participants.inc.php::getProject -> sql error: " . $mysql_error();
|
||||
} else if(mysql_num_rows($q)!=1) {
|
||||
return "register_participants.inc.php::getProject -> no project";
|
||||
}
|
||||
else {
|
||||
$returnval = mysql_fetch_assoc($q);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user