Merge pull request #9996 from nextcloud/bugfix/noid/Morikko-config-write-code-error
Change status code when config is write protected
This commit is contained in:
commit
f5698910fc
2 changed files with 9 additions and 3 deletions
|
@ -249,14 +249,18 @@ class OC {
|
|||
if (self::$CLI) {
|
||||
echo $l->t('Cannot write into "config" directory!')."\n";
|
||||
echo $l->t('This can usually be fixed by giving the webserver write access to the config directory')."\n";
|
||||
echo "\n";
|
||||
echo $l->t('See %s', [ $urlGenerator->linkToDocs('admin-dir_permissions') ])."\n";
|
||||
echo "\n";
|
||||
echo $l->t('Or, if you prefer to keep config.php file read only, set the option "config_is_read_only" to true in it.')."\n";
|
||||
echo $l->t('See %s', [ $urlGenerator->linkToDocs('admin-config') ])."\n";
|
||||
exit;
|
||||
} else {
|
||||
OC_Template::printErrorPage(
|
||||
$l->t('Cannot write into "config" directory!'),
|
||||
$l->t('This can usually be fixed by giving the webserver write access to the config directory. See %s',
|
||||
[ $urlGenerator->linkToDocs('admin-dir_permissions') ])
|
||||
[ $urlGenerator->linkToDocs('admin-dir_permissions') ]) . '. '
|
||||
. $l->t('Or, if you prefer to keep config.php file read only, set the option "config_is_read_only" to true in it. See %s',
|
||||
[ $urlGenerator->linkToDocs('admin-config') ] )
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -745,7 +745,9 @@ class OC_Util {
|
|||
$errors[] = array(
|
||||
'error' => $l->t('Cannot write into "config" directory'),
|
||||
'hint' => $l->t('This can usually be fixed by giving the webserver write access to the config directory. See %s',
|
||||
[$urlGenerator->linkToDocs('admin-dir_permissions')])
|
||||
[ $urlGenerator->linkToDocs('admin-dir_permissions') ]) . '. '
|
||||
. $l->t('Or, if you prefer to keep config.php file read only, set the option "config_is_read_only" to true in it. See %s',
|
||||
[ $urlGenerator->linkToDocs('admin-config') ] )
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue