summaryrefslogtreecommitdiffstats
path: root/apps/files/index.php
diff options
context:
space:
mode:
authorBjoern Schiessle <schiessle@owncloud.com>2013-10-04 12:30:49 +0200
committerBjoern Schiessle <schiessle@owncloud.com>2013-10-04 12:30:49 +0200
commit51295e9a6b9cd8e351132e988858b5d4bd223968 (patch)
tree7d2da02957552a8ac49eb6f2f3bd6b08e1049406 /apps/files/index.php
parenta223cf769a670c1c8926baf4ded445af300d056d (diff)
parent514d7a884a5211fe246487421ea8103202d004d7 (diff)
downloadnextcloud-server-51295e9a6b9cd8e351132e988858b5d4bd223968.tar.gz
nextcloud-server-51295e9a6b9cd8e351132e988858b5d4bd223968.zip
Merge branch 'master' into sharing_mail_notification_master
Conflicts: apps/files/index.php apps/files/templates/index.php
Diffstat (limited to 'apps/files/index.php')
-rw-r--r--apps/files/index.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/files/index.php b/apps/files/index.php
index 62e1438fc63..8d877be8ac9 100644
--- a/apps/files/index.php
+++ b/apps/files/index.php
@@ -104,8 +104,12 @@ if ($needUpgrade) {
$storageInfo=OC_Helper::getStorageInfo($dir);
$maxUploadFilesize=OCP\Util::maxUploadFilesize($dir);
$publicUploadEnabled = \OC_Appconfig::getValue('core', 'shareapi_allow_public_upload', 'yes');
+ // if the encryption app is disabled, than everything is fine (INIT_SUCCESSFUL status code)
+ $encryptionInitStatus = 2;
if (OC_App::isEnabled('files_encryption')) {
$publicUploadEnabled = 'no';
+ $session = new \OCA\Encryption\Session(new \OC\Files\View('/'));
+ $encryptionInitStatus = $session->getInitialized();
}
$trashEnabled = \OCP\App::isEnabled('files_trashbin');
@@ -134,6 +138,7 @@ if ($needUpgrade) {
$tmpl->assign('publicUploadEnabled', $publicUploadEnabled);
$tmpl->assign("encryptedFiles", \OCP\Util::encryptedFiles());
$tmpl->assign("mailNotificationEnabled", \OC_Appconfig::getValue('core', 'shareapi_allow_mail_notification', 'yes'));
+ $tmpl->assign("encryptionInitStatus", $encryptionInitStatus);
$tmpl->assign('disableSharing', false);
$tmpl->assign('ajaxLoad', $ajaxLoad);