diff options
author | msquare <msquare@notrademark.de> | 2019-08-21 01:27:38 +0200 |
---|---|---|
committer | msquare <msquare@notrademark.de> | 2019-08-21 01:27:38 +0200 |
commit | 8139f2fb4ecbdc94cd5fec9d40cf0316730196c9 (patch) | |
tree | 520b2fc4d8ac9d1c08c5ec4ddd15bc2077ee02ae | |
parent | a521ace9f7648029ff69d4777bdcc20517e91e95 (diff) |
redo fix shift view bug
-rw-r--r-- | includes/controller/shifts_controller.php | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/includes/controller/shifts_controller.php b/includes/controller/shifts_controller.php index 804c7f32..caf124ba 100644 --- a/includes/controller/shifts_controller.php +++ b/includes/controller/shifts_controller.php @@ -269,12 +269,11 @@ function shift_controller() $shifttype = ShiftType($shift['shifttype_id']); $room = Room($shift['RID']); - $angeltypes_source = AngelTypes(); - $angeltypes = []; + $angeltypes = AngelTypes(); $user_shifts = Shifts_by_user($user->id); $shift_signup_state = new ShiftSignupState(ShiftSignupState::OCCUPIED, 0); - foreach ($angeltypes_source as &$angeltype) { + foreach ($angeltypes as &$angeltype) { $needed_angeltype = NeededAngeltype_by_Shift_and_Angeltype($shift, $angeltype); if (empty($needed_angeltype)) { continue; @@ -293,7 +292,6 @@ function shift_controller() ); $shift_signup_state->combineWith($angeltype_signup_state); $angeltype['shift_signup_state'] = $angeltype_signup_state; - $angeltypes[] = $angeltype; } return [ |