aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorprovokateurin <kate@provokateurin.de>2024-09-15 22:39:18 +0200
committerbackportbot[bot] <backportbot[bot]@users.noreply.github.com>2024-09-16 09:33:01 +0000
commitca5b22a5e8be6c0d9f7e346ab9d6aa0d0dbecc8e (patch)
treed2e3fecc54ab6b003dc8baa51f6cf1f2eb303b18
parentbbe3b99254192f4093c667ce4ff12a2e68463472 (diff)
downloadnextcloud-server-backport/48050/stable29.tar.gz
nextcloud-server-backport/48050/stable29.zip
fix(weather_status): Fix search address errors when offlinebackport/48050/stable29
Signed-off-by: provokateurin <kate@provokateurin.de>
-rw-r--r--apps/weather_status/lib/Service/WeatherStatusService.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/weather_status/lib/Service/WeatherStatusService.php b/apps/weather_status/lib/Service/WeatherStatusService.php
index ed416d09a87..0ecac2ea57b 100644
--- a/apps/weather_status/lib/Service/WeatherStatusService.php
+++ b/apps/weather_status/lib/Service/WeatherStatusService.php
@@ -275,6 +275,9 @@ class WeatherStatusService {
];
$url = 'https://nominatim.openstreetmap.org/search';
$results = $this->requestJSON($url, $params);
+ if ($results['error'] !== null) {
+ return $results;
+ }
if (count($results) > 0) {
return $results[0];
}