summaryrefslogtreecommitdiffstats
path: root/apps/files/index.php
diff options
context:
space:
mode:
authorBjoern Schiessle <schiessle@owncloud.com>2013-08-17 13:15:22 +0200
committerBjoern Schiessle <schiessle@owncloud.com>2013-08-17 13:15:22 +0200
commitcabe92ef1240e171a812f5822ac69b4d7742fd71 (patch)
tree469e9089107d440da0c12c291abbd626d6d08b33 /apps/files/index.php
parent7adfc27cafa6f94962a33c158af9c45e71e012c5 (diff)
parentd3e2f31adad5eeaf415154dd2fb88cb9fec0b3c1 (diff)
downloadnextcloud-server-cabe92ef1240e171a812f5822ac69b4d7742fd71.tar.gz
nextcloud-server-cabe92ef1240e171a812f5822ac69b4d7742fd71.zip
Merge branch 'master' into decrypt_files_again
Conflicts: apps/files_encryption/tests/keymanager.php
Diffstat (limited to 'apps/files/index.php')
-rw-r--r--apps/files/index.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/apps/files/index.php b/apps/files/index.php
index 57171ac3b5a..94c792303da 100644
--- a/apps/files/index.php
+++ b/apps/files/index.php
@@ -126,6 +126,12 @@ if ($needUpgrade) {
$publicUploadEnabled = 'no';
}
+ $trashEnabled = \OCP\App::isEnabled('files_trashbin');
+ $trashEmpty = true;
+ if ($trashEnabled) {
+ $trashEmpty = \OCA\Files_Trashbin\Trashbin::isEmpty($user);
+ }
+
OCP\Util::addscript('files', 'fileactions');
OCP\Util::addscript('files', 'files');
OCP\Util::addscript('files', 'keyboardshortcuts');
@@ -136,7 +142,8 @@ if ($needUpgrade) {
$tmpl->assign('isCreatable', \OC\Files\Filesystem::isCreatable($dir . '/'));
$tmpl->assign('permissions', $permissions);
$tmpl->assign('files', $files);
- $tmpl->assign('trash', \OCP\App::isEnabled('files_trashbin'));
+ $tmpl->assign('trash', $trashEnabled);
+ $tmpl->assign('trashEmpty', $trashEmpty);
$tmpl->assign('uploadMaxFilesize', $maxUploadFilesize);
$tmpl->assign('uploadMaxHumanFilesize', OCP\Util::humanFileSize($maxUploadFilesize));
$tmpl->assign('allowZipDownload', intval(OCP\Config::getSystemValue('allowZipDownload', true)));