aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files_trashbin/ajax/delete.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files_trashbin/ajax/delete.php')
-rw-r--r--apps/files_trashbin/ajax/delete.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/files_trashbin/ajax/delete.php b/apps/files_trashbin/ajax/delete.php
index 7a6bd1342ea..f41482bef55 100644
--- a/apps/files_trashbin/ajax/delete.php
+++ b/apps/files_trashbin/ajax/delete.php
@@ -15,7 +15,9 @@ if ($path_parts['dirname'] == '.') {
$timestamp = null;
}
-if (OCA\Files_Trashbin\Trashbin::delete($filename, $timestamp)) {
+OCA\Files_Trashbin\Trashbin::delete($filename, $timestamp);
+
+if (!OCA\Files_Trashbin\Trashbin::file_exists($filename)) {
OCP\JSON::success(array("data" => array("filename" => $file)));
} else {
$l = OC_L10N::get('files_trashbin');