summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorris Jobke <morris.jobke@gmail.com>2013-06-15 01:31:32 -0700
committerMorris Jobke <morris.jobke@gmail.com>2013-06-15 01:31:32 -0700
commitc99e7e97a3cf3e3c0629f6e8ca0839d190ef0b11 (patch)
tree048763a8642806da77a8f743ec39b79e4506ec3b
parentab411d2700c01886a67b30bce5f630cc6865a9bf (diff)
parentbb640df06e2d5e25f63ac8a84cdd3e747472f965 (diff)
downloadnextcloud-server-c99e7e97a3cf3e3c0629f6e8ca0839d190ef0b11.tar.gz
nextcloud-server-c99e7e97a3cf3e3c0629f6e8ca0839d190ef0b11.zip
Merge pull request #3301 from bastho/fix_filestrashbin_missing-sub-folder
Fix inexisting trashbin's sub-folders
-rw-r--r--apps/files_trashbin/lib/trash.php11
1 files changed, 9 insertions, 2 deletions
diff --git a/apps/files_trashbin/lib/trash.php b/apps/files_trashbin/lib/trash.php
index 2d1830a38f1..7b8d3cb4252 100644
--- a/apps/files_trashbin/lib/trash.php
+++ b/apps/files_trashbin/lib/trash.php
@@ -50,12 +50,19 @@ class Trashbin {
$view = new \OC\Files\View('/'. $user);
if (!$view->is_dir('files_trashbin')) {
$view->mkdir('files_trashbin');
+ }
+ if (!$view->is_dir('files_trashbin/files')) {
$view->mkdir('files_trashbin/files');
+ }
+ if (!$view->is_dir('files_trashbin/versions')) {
$view->mkdir('files_trashbin/versions');
+ }
+ if (!$view->is_dir('files_trashbin/keyfiles')) {
$view->mkdir('files_trashbin/keyfiles');
- $view->mkdir('files_trashbin/share-keys');
}
-
+ if (!$view->is_dir('files_trashbin/share-keys')) {
+ $view->mkdir('files_trashbin/share-keys');
+ }
$path_parts = pathinfo($file_path);
$filename = $path_parts['basename'];