From 46faf6d3ca437c8795af79f1851b4bd6b4a92280 Mon Sep 17 00:00:00 2001 From: Roeland Jago Douma Date: Sat, 6 Feb 2016 13:31:31 +0100 Subject: Fix exception on delete --- lib/private/share20/manager.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'lib/private/share20') diff --git a/lib/private/share20/manager.php b/lib/private/share20/manager.php index 7d0017bf6f7..33085410e1d 100644 --- a/lib/private/share20/manager.php +++ b/lib/private/share20/manager.php @@ -22,6 +22,7 @@ namespace OC\Share20; use OCP\Files\IRootFolder; +use OCP\Files\NotFoundException; use OCP\IUserManager; use OCP\Share\IManager; use OCP\Share\IProviderFactory; @@ -795,7 +796,11 @@ class Manager implements IManager { if ($share->getExpirationDate() !== null && $share->getExpirationDate() <= $today ) { - $this->deleteShare($share); + try { + $this->deleteShare($share); + } catch (NotFoundException $e) { + //Ignore since this basically means the share is deleted + } continue; } $added++; -- cgit v1.2.3