prevent recursion when moving a file to the trashbin

Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
Robin Appelman 2019-03-13 11:42:01 +01:00
parent f0c85a0f5f
commit 0d41138c6e
No known key found for this signature in database
GPG Key ID: 42B69D8A64526EFB
1 changed files with 4 additions and 1 deletions

View File

@ -99,7 +99,10 @@ class TrashManager implements ITrashManager {
}
try {
$backend = $this->getBackendForStorage($storage);
return $backend->moveToTrash($storage, $internalPath);
$this->trashPaused = true;
$result = $backend->moveToTrash($storage, $internalPath);
$this->trashPaused = false;
return $result;
} catch (BackendNotFoundException $e) {
return false;
}