Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion lib/Model/ShareWrapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,10 @@
$this->importAttributesFromDatabase($this->get('attributes', $data));

try {
$this->setExpirationDate(new DateTime($this->get('expiration', $data)));
$expirationDate = $this->get('expiration', $data);
if ($expirationDate !== '') {
$this->setExpirationDate(new DateTime($expirationDate));
}
} catch (\Exception $e) {
}

Expand Down Expand Up @@ -567,7 +570,7 @@
$this->setExpirationDate(new DateTime($expirationDate));
}
} catch (\Exception $e) {
Server::get(LoggerInterface::class)->warning('could not parse expiration date', ['exception' => $e]);

Check failure on line 573 in lib/Model/ShareWrapper.php

View workflow job for this annotation

GitHub Actions / static-psalm-analysis

UndefinedClass

lib/Model/ShareWrapper.php:573:4: UndefinedClass: Class, interface or enum named OCA\Circles\Model\Server does not exist (see https://psalm.dev/019)
}

$this->importAttributesFromDatabase($this->get('attributes', $data));
Expand Down
Loading