]> source.dussan.org Git - nextcloud-server.git/commitdiff
OC_Defaults is only used in error reporting
authorBart Visscher <bartv@thisnet.nl>
Wed, 25 Sep 2013 16:34:50 +0000 (18:34 +0200)
committerBart Visscher <bartv@thisnet.nl>
Fri, 4 Oct 2013 16:11:02 +0000 (18:11 +0200)
lib/private/config.php

index e773e6e2eb0254a311efbba6176ecf835cf38047..72423137fa331bbbb834175b7cba58d171fc6fff 100644 (file)
@@ -160,7 +160,6 @@ class Config {
         */
        private function writeData() {
                // Create a php file ...
-               $defaults = new \OC_Defaults;
                $content = "<?php\n";
                if ($this->debugMode) {
                        $content .= "define('DEBUG',true);\n";
@@ -172,6 +171,7 @@ class Config {
                // Write the file
                $result = @file_put_contents($this->configFilename, $content);
                if (!$result) {
+                       $defaults = new \OC_Defaults;
                        $url = $defaults->getDocBaseUrl() . '/server/5.0/admin_manual/installation/installation_source.html#set-the-directory-permissions';
                        throw new HintException(
                                "Can't write into config directory!",