From: Qingping Hou Date: Sat, 16 Feb 2013 22:44:51 +0000 (-0500) Subject: Properly delete empty directories in Trashbin X-Git-Tag: v5.0.0beta1~9^2~1 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=4b4b1f86925248a36c4cc62e91905e605b891e70;p=nextcloud-server.git Properly delete empty directories in Trashbin Instead of checking delted file size, we do a real check. this fixes #1688 --- 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');