From 2049a21348f1e1ea16bb12ca36a410262f907d0e Mon Sep 17 00:00:00 2001 From: =?utf8?q?C=C3=B4me=20Chilliet?= Date: Tue, 12 Apr 2022 14:26:24 +0200 Subject: [PATCH] Fix warning about optional parameter before required one MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fixes this warning: PHP Deprecated: Required parameter $logger follows optional parameter $principalPrefix in /var/www/html/apps/dav/lib/CalDAV/CalendarRoot.php on line 37 Signed-off-by: Côme Chilliet --- apps/dav/lib/CalDAV/CalendarRoot.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/apps/dav/lib/CalDAV/CalendarRoot.php b/apps/dav/lib/CalDAV/CalendarRoot.php index e08264b8f59..0c701d9cdcf 100644 --- a/apps/dav/lib/CalDAV/CalendarRoot.php +++ b/apps/dav/lib/CalDAV/CalendarRoot.php @@ -30,11 +30,14 @@ use Sabre\CalDAV\Backend; use Sabre\DAVACL\PrincipalBackend; class CalendarRoot extends \Sabre\CalDAV\CalendarRoot { - - /** @var LoggerInterface */ - private $logger; - - public function __construct(PrincipalBackend\BackendInterface $principalBackend, Backend\BackendInterface $caldavBackend, $principalPrefix = 'principals', LoggerInterface $logger) { + private LoggerInterface $logger; + + public function __construct( + PrincipalBackend\BackendInterface $principalBackend, + Backend\BackendInterface $caldavBackend, + $principalPrefix, + LoggerInterface $logger + ) { parent::__construct($principalBackend, $caldavBackend, $principalPrefix); $this->logger = $logger; } -- 2.39.5