diff options
Diffstat (limited to 'includes/model/Shifts_model.php')
-rw-r--r-- | includes/model/Shifts_model.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/includes/model/Shifts_model.php b/includes/model/Shifts_model.php index 2408eb49..01295fbc 100644 --- a/includes/model/Shifts_model.php +++ b/includes/model/Shifts_model.php @@ -80,12 +80,15 @@ function Shifts_from_frab() } /** - * @param array $room + * @param array|int $room * @return array[] */ function Shifts_by_room($room) { - return DB::select('SELECT * FROM `Shifts` WHERE `RID`=? ORDER BY `start`', [$room['RID']]); + return DB::select( + 'SELECT * FROM `Shifts` WHERE `RID`=? ORDER BY `start`', + [is_array($room) ? $room['RID'] : $room] + ); } /** |