mirror of
https://github.com/nextcloud/server.git
synced 2026-02-20 00:12:30 -05:00
fix(files_sharing): Allow deleting a share of a missing file
This can happen in various scenarios, we should allow the user to delete the share in this situation. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
0f5bf92456
commit
a60f9494ec
1 changed files with 2 additions and 0 deletions
|
|
@ -545,6 +545,8 @@ class ShareAPIController extends OCSController {
|
|||
$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 deleted share was not found, skip locking', ['exception' => $e]);
|
||||
}
|
||||
|
||||
if (!$this->canAccessShare($share)) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue