From 1bc51a059b81692a7e0245b377fe0245141bd3d8 Mon Sep 17 00:00:00 2001 From: Côme Chilliet Date: Mon, 19 Dec 2022 11:44:27 +0100 Subject: Fix parameter type for EntityCollection::setReadMarker in comments app MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Côme Chilliet --- apps/dav/lib/Comments/EntityCollection.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'apps') diff --git a/apps/dav/lib/Comments/EntityCollection.php b/apps/dav/lib/Comments/EntityCollection.php index 164c690afd0..2581ff0c367 100644 --- a/apps/dav/lib/Comments/EntityCollection.php +++ b/apps/dav/lib/Comments/EntityCollection.php @@ -162,12 +162,9 @@ class EntityCollection extends RootCollection implements IProperties { /** * Sets the read marker to the specified date for the logged in user - * - * @param \DateTime $value - * @return bool */ - public function setReadMarker($value) { - $dateTime = new \DateTime($value); + public function setReadMarker(?string $value): bool { + $dateTime = new \DateTime($value ?? 'now'); $user = $this->userSession->getUser(); $this->commentsManager->setReadMark($this->name, $this->id, $dateTime, $user); return true; -- cgit v1.2.3