diff options
author | Morris Jobke <hey@morrisjobke.de> | 2017-07-27 13:43:18 +0200 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2017-07-27 13:43:18 +0200 |
commit | c27498db7103aebac323c361007e0d8a2da16a34 (patch) | |
tree | cfe7bbb7b4abb89936ba9d35a70ef4f50d0c9213 /apps | |
parent | 65ade4b6d5a942ff781dad5396387facc86a95ed (diff) | |
download | nextcloud-server-c27498db7103aebac323c361007e0d8a2da16a34.tar.gz nextcloud-server-c27498db7103aebac323c361007e0d8a2da16a34.zip |
Use IConfig instead of static OCP\Config
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files_versions/lib/Storage.php | 4 | ||||
-rw-r--r-- | apps/user_ldap/appinfo/install.php | 5 | ||||
-rw-r--r-- | apps/user_ldap/lib/Configuration.php | 2 |
3 files changed, 6 insertions, 5 deletions
diff --git a/apps/files_versions/lib/Storage.php b/apps/files_versions/lib/Storage.php index 9aa9e6d5260..6e6b6aebb6d 100644 --- a/apps/files_versions/lib/Storage.php +++ b/apps/files_versions/lib/Storage.php @@ -161,7 +161,7 @@ class Storage { * store a new version of a file. */ public static function store($filename) { - if(\OCP\Config::getSystemValue('files_versions', Storage::DEFAULTENABLED)=='true') { + if(\OC::$server->getConfig()->getSystemValue('files_versions', Storage::DEFAULTENABLED)=='true') { // if the file gets streamed we need to remove the .part extension // to get the right target @@ -320,7 +320,7 @@ class Storage { */ public static function rollback($file, $revision) { - if(\OCP\Config::getSystemValue('files_versions', Storage::DEFAULTENABLED)=='true') { + if(\OC::$server->getConfig()->getSystemValue('files_versions', Storage::DEFAULTENABLED)=='true') { // add expected leading slash $file = '/' . ltrim($file, '/'); list($uid, $filename) = self::getUidAndFilename($file); diff --git a/apps/user_ldap/appinfo/install.php b/apps/user_ldap/appinfo/install.php index 43ec69a950b..09f9b412342 100644 --- a/apps/user_ldap/appinfo/install.php +++ b/apps/user_ldap/appinfo/install.php @@ -21,10 +21,11 @@ * along with this program. If not, see <http://www.gnu.org/licenses/> * */ -$state = OCP\Config::getSystemValue('ldapIgnoreNamingRules', 'doSet'); +$config = \OC::$server->getConfig(); +$state = $config->getSystemValue('ldapIgnoreNamingRules', 'doSet'); if($state === 'doSet') { OCP\Config::setSystemValue('ldapIgnoreNamingRules', false); } -$helper = new \OCA\User_LDAP\Helper(\OC::$server->getConfig()); +$helper = new \OCA\User_LDAP\Helper($config); $helper->setLDAPProvider(); diff --git a/apps/user_ldap/lib/Configuration.php b/apps/user_ldap/lib/Configuration.php index 851ff03cbb4..c65e6e34e2c 100644 --- a/apps/user_ldap/lib/Configuration.php +++ b/apps/user_ldap/lib/Configuration.php @@ -349,7 +349,7 @@ class Configuration { */ protected function getSystemValue($varName) { //FIXME: if another system value is added, softcode the default value - return \OCP\Config::getSystemValue($varName, false); + return \OC::$server->getConfig()->getSystemValue($varName, false); } /** |