From 4b4b1f86925248a36c4cc62e91905e605b891e70 Mon Sep 17 00:00:00 2001 From: Qingping Hou Date: Sat, 16 Feb 2013 17:44:51 -0500 Subject: [PATCH] Properly delete empty directories in Trashbin Instead of checking delted file size, we do a real check. this fixes #1688 --- apps/files_trashbin/ajax/delete.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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'); -- 2.39.5