From: Simon Spannagel Date: Fri, 16 Oct 2020 05:47:29 +0000 (+0200) Subject: CalDavBackend: check if timerange is array before accessing X-Git-Tag: v20.0.2RC1~76^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b1d3877625cb6ef13a80faa377fcf68e6fd0198d;p=nextcloud-server.git CalDavBackend: check if timerange is array before accessing Signed-off-by: Simon Spannagel --- diff --git a/apps/dav/lib/CalDAV/CalDavBackend.php b/apps/dav/lib/CalDAV/CalDavBackend.php index 91326128721..82c14086833 100644 --- a/apps/dav/lib/CalDAV/CalDavBackend.php +++ b/apps/dav/lib/CalDAV/CalDavBackend.php @@ -16,6 +16,7 @@ * @author Thomas Citharel * @author Thomas Müller * @author Vinicius Cubas Brand + * @author Simon Spannagel * * @license AGPL-3.0 * @@ -1364,7 +1365,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription $requirePostFilter = false; } // There was a time-range filter - if ($componentType === 'VEVENT' && isset($filters['comp-filters'][0]['time-range'])) { + if ($componentType === 'VEVENT' && isset($filters['comp-filters'][0]['time-range']) && is_array($filters['comp-filters'][0]['time-range'])) { $timeRange = $filters['comp-filters'][0]['time-range']; // If start time OR the end time is not specified, we can do a