summaryrefslogtreecommitdiffstats
path: root/apps/files_trashbin
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2016-02-25 16:55:36 +0100
committerThomas Müller <thomas.mueller@tmit.eu>2016-02-25 16:55:36 +0100
commit29e3c4a60e014cbc93bf4e1b032465a58188ba47 (patch)
tree61d59c3bace84b20167ba2a075599cc31d45e20e /apps/files_trashbin
parent35423102af447171ef689f8a3e2f6ab3b2d89848 (diff)
parentaac6932e92c82b7362b5772e74a59fa6a10f6a1d (diff)
downloadnextcloud-server-29e3c4a60e014cbc93bf4e1b032465a58188ba47.tar.gz
nextcloud-server-29e3c4a60e014cbc93bf4e1b032465a58188ba47.zip
Merge pull request #22628 from owncloud/fix-thrashbin-cronjob
Skip users with no trashbin
Diffstat (limited to 'apps/files_trashbin')
-rw-r--r--apps/files_trashbin/lib/backgroundjob/expiretrash.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/files_trashbin/lib/backgroundjob/expiretrash.php b/apps/files_trashbin/lib/backgroundjob/expiretrash.php
index 7f4f4823918..4ee0658840b 100644
--- a/apps/files_trashbin/lib/backgroundjob/expiretrash.php
+++ b/apps/files_trashbin/lib/backgroundjob/expiretrash.php
@@ -120,6 +120,12 @@ class ExpireTrash extends \OC\BackgroundJob\TimedJob {
return false;
}
+ //Check if this user has a trashbin directory
+ $view = new \OC\Files\View('/' . $user);
+ if (!$view->is_dir('/files_trashbin/files')){
+ return false;
+ }
+
\OC_Util::tearDownFS();
\OC_Util::setupFS($user);