diff --git a/apps/files_sharing/lib/Controller/ShareAPIController.php b/apps/files_sharing/lib/Controller/ShareAPIController.php index 37aa26ac47509..6511135a5109a 100644 --- a/apps/files_sharing/lib/Controller/ShareAPIController.php +++ b/apps/files_sharing/lib/Controller/ShareAPIController.php @@ -539,6 +539,8 @@ public function deleteShare(string $id): DataResponse { $this->lock($share->getNode()); } catch (LockedException $e) { throw new OCSNotFoundException($this->l->t('Could not delete share')); + } catch (NotFoundException $e) { + $this->logger->debug('File of to be deleted share was not found, skip locking', ['exception' => $e]); } if (!$this->canAccessShare($share)) {