summaryrefslogtreecommitdiffstats
path: root/apps/files_encryption/lib/util.php
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-02-13 16:28:49 +0100
committerRobin Appelman <icewind@owncloud.com>2014-02-13 16:28:49 +0100
commit181bbd4325ea2b21ff8ecca93eb5ac839d6a739d (patch)
tree18fdd4bfdbd2de538ebe996e7ddb580a07450994 /apps/files_encryption/lib/util.php
parent4b84e3a7e8bf7dc0a8e62074803f97a81571ca22 (diff)
downloadnextcloud-server-181bbd4325ea2b21ff8ecca93eb5ac839d6a739d.tar.gz
nextcloud-server-181bbd4325ea2b21ff8ecca93eb5ac839d6a739d.zip
Remove usage of legacy OC_Appconfig
Diffstat (limited to 'apps/files_encryption/lib/util.php')
-rw-r--r--apps/files_encryption/lib/util.php12
1 files changed, 8 insertions, 4 deletions
diff --git a/apps/files_encryption/lib/util.php b/apps/files_encryption/lib/util.php
index ae3e2a2e15a..13184b50dbf 100644
--- a/apps/files_encryption/lib/util.php
+++ b/apps/files_encryption/lib/util.php
@@ -63,8 +63,10 @@ class Util {
$this->client = $client;
$this->userId = $userId;
- $this->publicShareKeyId = \OC_Appconfig::getValue('files_encryption', 'publicShareKeyId');
- $this->recoveryKeyId = \OC_Appconfig::getValue('files_encryption', 'recoveryKeyId');
+ $appConfig = \OC::$server->getAppConfig();
+
+ $this->publicShareKeyId = $appConfig->getValue('files_encryption', 'publicShareKeyId');
+ $this->recoveryKeyId = $appConfig->getValue('files_encryption', 'recoveryKeyId');
$this->userDir = '/' . $this->userId;
$this->fileFolderName = 'files';
@@ -1113,9 +1115,11 @@ class Util {
*/
public function getSharingUsersArray($sharingEnabled, $filePath, $currentUserId = false) {
+ $appConfig = \OC::$server->getAppConfig();
+
// Check if key recovery is enabled
if (
- \OC_Appconfig::getValue('files_encryption', 'recoveryAdminEnabled')
+ $appConfig->getValue('files_encryption', 'recoveryAdminEnabled')
&& $this->recoveryEnabledForUser()
) {
$recoveryEnabled = true;
@@ -1144,7 +1148,7 @@ class Util {
// Admin UID to list of users to share to
if ($recoveryEnabled) {
// Find recoveryAdmin user ID
- $recoveryKeyId = \OC_Appconfig::getValue('files_encryption', 'recoveryKeyId');
+ $recoveryKeyId = $appConfig->getValue('files_encryption', 'recoveryKeyId');
// Add recoveryAdmin to list of users sharing
$userIds[] = $recoveryKeyId;
}