Make check for writable apps dir configurable

Conflicts:

	config/config.sample.php
This commit is contained in:
Bart Visscher 2012-06-05 17:51:41 +02:00
parent 637f8398ba
commit 98bc916016
2 changed files with 6 additions and 1 deletions

View File

@ -31,6 +31,11 @@ $CONFIG = array(
"loglevel" => "",
"passwordsalt" => "",
"updatechecker" => true,
/* Set this to false to disable the check for writable apps dir.
* If the apps dir is not writable, you can't download&install extra apps
* in the admin apps menu.
*/
"writable_appsdir" => true,
// "datadirectory" => ""
);
?>

View File

@ -29,7 +29,7 @@ class OC_Util {
}
// Check if apps folder is writable.
if(!is_writable(OC::$SERVERROOT."/apps/")) {
if(OC_Config::getValue('writable_appsdir', true) && !is_writable(OC::$SERVERROOT."/apps/")) {
$tmpl = new OC_Template( '', 'error', 'guest' );
$tmpl->assign('errors',array(1=>array('error'=>"Can't write into apps directory 'apps'",'hint'=>"You can usually fix this by giving the webserver user write access to the config directory in owncloud")));
$tmpl->printPage();