From bff012a2b292e8083725d5bc5dda5fde1612a9f7 Mon Sep 17 00:00:00 2001 From: Thomas Citharel Date: Thu, 4 Jun 2020 11:08:20 +0200 Subject: [PATCH] Fix empty event UUID reminder notifications Signed-off-by: Thomas Citharel --- .../CalDAV/Reminder/NotificationProvider/PushProvider.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/apps/dav/lib/CalDAV/Reminder/NotificationProvider/PushProvider.php b/apps/dav/lib/CalDAV/Reminder/NotificationProvider/PushProvider.php index 7e560159950..1bd79f0b20f 100644 --- a/apps/dav/lib/CalDAV/Reminder/NotificationProvider/PushProvider.php +++ b/apps/dav/lib/CalDAV/Reminder/NotificationProvider/PushProvider.php @@ -94,8 +94,10 @@ class PushProvider extends AbstractProvider { $eventDetails = $this->extractEventDetails($vevent); $eventDetails['calendar_displayname'] = $calendarDisplayName; $eventUUID = (string) $vevent->UID; - // Empty Notification ObjectId will be catched by OC\Notification\Notification - $eventUUIDHash = $eventUUID ? hash('sha256', $eventUUID, false) : ''; + if (!$eventUUID) { + return; + }; + $eventUUIDHash = hash('sha256', $eventUUID, false); foreach($users as $user) { /** @var INotification $notification */ -- 2.39.5