summaryrefslogtreecommitdiffstats
path: root/lib/private
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2015-12-02 14:49:40 +0100
committerMorris Jobke <hey@morrisjobke.de>2015-12-02 14:49:40 +0100
commitbaecfc4080214f37708f8c233c0f9b33df7571fd (patch)
tree89f2fef954606433ada44284b623dc8a5d066749 /lib/private
parent8d218bf3ef842d76c2b97a175b28e13054497952 (diff)
downloadnextcloud-server-baecfc4080214f37708f8c233c0f9b33df7571fd.tar.gz
nextcloud-server-baecfc4080214f37708f8c233c0f9b33df7571fd.zip
Reduce OC_Config usage in lib/
* replaced by proper public interfaces
Diffstat (limited to 'lib/private')
-rw-r--r--lib/private/files/filesystem.php6
-rw-r--r--lib/private/preview/office.php5
-rw-r--r--lib/private/share/share.php2
3 files changed, 7 insertions, 6 deletions
diff --git a/lib/private/files/filesystem.php b/lib/private/files/filesystem.php
index 0f7508b8f26..9f243c15a4c 100644
--- a/lib/private/files/filesystem.php
+++ b/lib/private/files/filesystem.php
@@ -386,7 +386,7 @@ class Filesystem {
throw new \OC\User\NoUserException('Backends provided no user object for ' . $user);
}
- $homeStorage = \OC_Config::getValue('objectstore');
+ $homeStorage = \OC::$server->getConfig()->getSystemValue('objectstore');
if (!empty($homeStorage)) {
// sanity checks
if (empty($homeStorage['class'])) {
@@ -458,7 +458,7 @@ class Filesystem {
* @param string $user user name
*/
private static function mountCacheDir($user) {
- $cacheBaseDir = \OC_Config::getValue('cache_path', '');
+ $cacheBaseDir = \OC::$server->getConfig()->getSystemValue('cache_path', '');
if ($cacheBaseDir !== '') {
$cacheDir = rtrim($cacheBaseDir, '/') . '/' . $user;
if (!file_exists($cacheDir)) {
@@ -603,7 +603,7 @@ class Filesystem {
static public function isFileBlacklisted($filename) {
$filename = self::normalizePath($filename);
- $blacklist = \OC_Config::getValue('blacklisted_files', array('.htaccess'));
+ $blacklist = \OC::$server->getConfig()->getSystemValue('blacklisted_files', array('.htaccess'));
$filename = strtolower(basename($filename));
return in_array($filename, $blacklist);
}
diff --git a/lib/private/preview/office.php b/lib/private/preview/office.php
index 415220ed4af..acf3683def0 100644
--- a/lib/private/preview/office.php
+++ b/lib/private/preview/office.php
@@ -79,8 +79,9 @@ abstract class Office extends Provider {
private function initCmd() {
$cmd = '';
- if (is_string(\OC_Config::getValue('preview_libreoffice_path', null))) {
- $cmd = \OC_Config::getValue('preview_libreoffice_path', null);
+ $libreOfficePath = \OC::$server->getConfig()->getSystemValue('preview_libreoffice_path', null);
+ if (is_string($libreOfficePath)) {
+ $cmd = $libreOfficePath;
}
$whichLibreOffice = shell_exec('command -v libreoffice');
diff --git a/lib/private/share/share.php b/lib/private/share/share.php
index e59cd3bc8c5..70f9a6e8920 100644
--- a/lib/private/share/share.php
+++ b/lib/private/share/share.php
@@ -1149,7 +1149,7 @@ class Share extends Constants {
if (!empty($ids)) {
$ids = "'".implode("','", $ids)."'";
// TODO this should be done with Doctrine platform objects
- if (\OC_Config::getValue( "dbtype") === 'oci') {
+ if (\OC::$server->getConfig()->getSystemValue("dbtype") === 'oci') {
$andOp = 'BITAND(`permissions`, ?)';
} else {
$andOp = '`permissions` & ?';