forked from GNUsocial/gnu-social
Added locales_path to site admin panel
This commit is contained in:
parent
08165c8f03
commit
409ce3556d
@ -93,7 +93,7 @@ class SiteadminpanelAction extends AdminPanelAction
|
|||||||
static $settings = array('site' => array('name', 'broughtby', 'broughtbyurl',
|
static $settings = array('site' => array('name', 'broughtby', 'broughtbyurl',
|
||||||
'email', 'timezone', 'language',
|
'email', 'timezone', 'language',
|
||||||
'ssl', 'sslserver', 'site', 'path',
|
'ssl', 'sslserver', 'site', 'path',
|
||||||
'textlimit', 'dupelimit'),
|
'textlimit', 'dupelimit', 'locale_path'),
|
||||||
'snapshot' => array('run', 'reporturl', 'frequency'));
|
'snapshot' => array('run', 'reporturl', 'frequency'));
|
||||||
|
|
||||||
static $booleans = array('site' => array('private', 'inviteonly', 'closed', 'fancy'));
|
static $booleans = array('site' => array('private', 'inviteonly', 'closed', 'fancy'));
|
||||||
@ -216,6 +216,14 @@ class SiteadminpanelAction extends AdminPanelAction
|
|||||||
$this->clientError(_("Dupe limit must 1 or more seconds."));
|
$this->clientError(_("Dupe limit must 1 or more seconds."));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Validate locales path
|
||||||
|
|
||||||
|
// XXX: What else do we need to validate for lacales path here? --Z
|
||||||
|
|
||||||
|
if (!empty($values['site']['locale_path']) && !is_readable($values['site']['locale_path'])) {
|
||||||
|
$this->clientError(sprintf(_("Locales directory not readable: %s"), $values['site']['locale_path']));
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user