diff --git a/lib/Service/SynchronizationService.php b/lib/Service/SynchronizationService.php index 920ec6e8..80d7069a 100644 --- a/lib/Service/SynchronizationService.php +++ b/lib/Service/SynchronizationService.php @@ -385,6 +385,10 @@ public function getAllObjectsFromApi(Synchronization $synchronization, ?bool $is // Make the initial API call $response = $this->callService->call(source: $source, endpoint: $endpoint, method: 'GET', config: $config)->getResponse(); $body = json_decode($response['body'], true); + if (empty($body) === true) { + // @todo log that we got a empty response + return []; + } $objects = array_merge($objects, $this->getAllObjectsFromArray(array: $body, synchronization: $synchronization)); // Return a single object or empty array if in test mode diff --git a/src/modals/Modals.vue b/src/modals/Modals.vue index 86b03c70..c0287073 100644 --- a/src/modals/Modals.vue +++ b/src/modals/Modals.vue @@ -27,7 +27,7 @@ import { navigationStore } from '../store/store.js' - + diff --git a/src/modals/Synchronization/TestSynchronization.vue b/src/modals/Synchronization/TestSynchronization.vue index d9694105..7e83dde4 100644 --- a/src/modals/Synchronization/TestSynchronization.vue +++ b/src/modals/Synchronization/TestSynchronization.vue @@ -3,8 +3,7 @@ import { synchronizationStore, navigationStore } from '../../store/store.js'