From a0fb34420e7e2d20446f69ba0cabc01ccf759b55 Mon Sep 17 00:00:00 2001 From: SimonGschnell Date: Tue, 27 May 2025 14:30:34 +0200 Subject: [PATCH] fix(Stundenplan API):corrects little bug with if statement check --- application/controllers/api/frontend/v1/Stundenplan.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/application/controllers/api/frontend/v1/Stundenplan.php b/application/controllers/api/frontend/v1/Stundenplan.php index 61a9e8f54..35b7ccc56 100644 --- a/application/controllers/api/frontend/v1/Stundenplan.php +++ b/application/controllers/api/frontend/v1/Stundenplan.php @@ -81,14 +81,11 @@ class Stundenplan extends FHCAPI_Controller $lv_id = $this->input->get('lv_id', TRUE); $stundenplan_events = $this->stundenplanlib->getStundenplan($start_date,$end_date,$lv_id); + $stundenplan_events = $this->getDataOrTerminateWithError($stundenplan_events); if( is_null($stundenplan_events) || isEmptyArray($stundenplan_events) ) { $stundenplan_events = array(); } - else - { - $stundenplan_events = $this->getDataOrTerminateWithError($stundenplan_events); - } // fetching moodle events $moodle_events = [];