fix errors generated with no attendees
This commit is contained in:
@@ -628,16 +628,12 @@ function _booking_rooms_cleanup($nid)
|
||||
|
||||
/**
|
||||
* Function for cleaning up study groups by removing people that have withdrawn their registration
|
||||
* @param $sid - the study group id to clean up
|
||||
* @param nothing - processes all defined study groups for the current event
|
||||
* @return nothing
|
||||
*/
|
||||
function _booking_studygroup_cleanup($sid)
|
||||
function _booking_studygroup_cleanup()
|
||||
{
|
||||
global $event;
|
||||
|
||||
//select any entries already in the mapping table
|
||||
$group_mapping_query = db_query("SELECT * FROM {booking_studygroup_mapping} WHERE booking_eventid = :eid AND booking_studygroup_id = :sid", array(':eid' => $event->eid, ':sid' => $sid));
|
||||
$group_mapping = $group_mapping_query->fetchAllAssoc('sid');
|
||||
|
||||
//search for entries already in the mapping table that have a booking_status of 3 (not coming)
|
||||
$to_remove_query = db_query("SELECT m.* FROM {booking_studygroup_mapping} m
|
||||
@@ -668,7 +664,6 @@ function _booking_person_studygroups_cleanup($nid)
|
||||
{
|
||||
global $event;
|
||||
|
||||
|
||||
//first of all make sure we need to do anything
|
||||
if (variable_get('booking_enable_studygroups', 0) == 1)
|
||||
{
|
||||
|
Reference in New Issue
Block a user