summaryrefslogtreecommitdiffstats
path: root/apps/files_trashbin/lib
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-03-24 12:33:44 +0100
committerRobin Appelman <icewind@owncloud.com>2014-03-24 12:33:44 +0100
commit6b66b42f6e4399676677bd6f6534ad3c33c8404f (patch)
treefdf282e8b641517f07caff96aca6b07f756130f8 /apps/files_trashbin/lib
parent38b1529c2a24a0fc58ce78a444f918750442a8aa (diff)
downloadnextcloud-server-6b66b42f6e4399676677bd6f6534ad3c33c8404f.tar.gz
nextcloud-server-6b66b42f6e4399676677bd6f6534ad3c33c8404f.zip
catch the case where files_trashbin/files doesn't exist
Diffstat (limited to 'apps/files_trashbin/lib')
-rw-r--r--apps/files_trashbin/lib/trashbin.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/files_trashbin/lib/trashbin.php b/apps/files_trashbin/lib/trashbin.php
index 62879b0ca85..7b14a4ec081 100644
--- a/apps/files_trashbin/lib/trashbin.php
+++ b/apps/files_trashbin/lib/trashbin.php
@@ -922,8 +922,11 @@ class Trashbin {
$view = new \OC\Files\View('/' . $user . '/files_trashbin');
$dh = $view->opendir('/files');
+ if (!$dh) {
+ return false;
+ }
while ($file = readdir($dh)) {
- if($file !== '.' and $file !== '..'){
+ if ($file !== '.' and $file !== '..') {
return false;
}
}