File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ public function getData(Feed $feed): array
7070 $ baseUri = $ secrets ->apiBaseUri ;
7171 $ sportCenterId = $ configuration ['sport_center_id ' ] ?? null ;
7272
73- if (empty ( $ baseUri) || empty ( $ sportCenterId) ) {
73+ if ($ baseUri === null || $ baseUri === '' || $ sportCenterId === null || $ sportCenterId === '' ) {
7474 return $ result ;
7575 }
7676
@@ -91,7 +91,7 @@ private function parseBrndBooking(array $booking): array
9191 {
9292 // Parse start time
9393 $ startDateTime = null ;
94- if (!empty ($ booking ['dato ' ]) && ! empty ($ booking ['starttid ' ])) {
94+ if (!empty ($ booking ['dato ' ]) && isset ( $ booking [ ' starttid ' ]) && is_string ($ booking ['starttid ' ])) {
9595 // Trim starttid to 6 digits after dot for microseconds
9696 $ starttid = preg_replace ('/\.(\d{6})\d+$/ ' , '.$1 ' , $ booking ['starttid ' ]);
9797 $ dateOnly = substr ($ booking ['dato ' ], 0 , 10 );
@@ -101,7 +101,7 @@ private function parseBrndBooking(array $booking): array
101101
102102 // Parse end time
103103 $ endDateTime = null ;
104- if (!empty ($ booking ['dato ' ]) && ! empty ($ booking ['sluttid ' ])) {
104+ if (!empty ($ booking ['dato ' ]) && isset ( $ booking [ ' sluttid ' ]) && is_string ($ booking ['sluttid ' ])) {
105105 $ sluttid = preg_replace ('/\.(\d{6})\d+$/ ' , '.$1 ' , $ booking ['sluttid ' ]);
106106 $ dateOnly = substr ($ booking ['dato ' ], 0 , 10 );
107107 $ dateTimeString = $ dateOnly . ' ' . $ sluttid ;
You can’t perform that action at this time.
0 commit comments