From 9ab896989f04dd1020dc32f350a2846080e5a6bf Mon Sep 17 00:00:00 2001 From: Varun Patil Date: Thu, 13 Apr 2023 23:37:30 -0700 Subject: [PATCH] tw: catch exeption not error Signed-off-by: Varun Patil --- lib/Db/TimelineWritePlaces.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Db/TimelineWritePlaces.php b/lib/Db/TimelineWritePlaces.php index 40afcd89..ba3489ed 100644 --- a/lib/Db/TimelineWritePlaces.php +++ b/lib/Db/TimelineWritePlaces.php @@ -37,14 +37,14 @@ trait TimelineWritePlaces if ($lat || $lon || $oldLat || $oldLon) { try { $mapCluster = $this->mapGetCluster($mapCluster, $lat, $lon, $oldLat, $oldLon); - } catch (\Error $e) { + } catch (\Exception $e) { $logger = \OC::$server->get(LoggerInterface::class); $logger->log(3, 'Error updating map cluster data: '.$e->getMessage(), ['app' => 'memories']); } try { $osmIds = $this->updatePlacesData($fileId, $lat, $lon); - } catch (\Error $e) { + } catch (\Exception $e) { $logger = \OC::$server->get(LoggerInterface::class); $logger->log(3, 'Error updating places data: '.$e->getMessage(), ['app' => 'memories']); }