Make site profiles work
This commit is contained in:
@@ -113,6 +113,10 @@ class StatusNet
|
||||
StatusNet::initDefaults($server, $path);
|
||||
StatusNet::loadConfigFile($conffile);
|
||||
|
||||
$sprofile = common_config('site', 'profile');
|
||||
if (!empty($sprofile)) {
|
||||
StatusNet::loadSiteProfile($sprofile);
|
||||
}
|
||||
// Load settings from database; note we need autoload for this
|
||||
Config::loadSettings();
|
||||
|
||||
@@ -302,6 +306,13 @@ class StatusNet
|
||||
}
|
||||
}
|
||||
|
||||
public static function loadSiteProfile($name)
|
||||
{
|
||||
global $config;
|
||||
$settings = SiteProfile::getSettings($name);
|
||||
$config = array_replace_recursive($config, $settings);
|
||||
}
|
||||
|
||||
protected function _sn_to_path($sn)
|
||||
{
|
||||
$past_root = substr($sn, 1);
|
||||
|
Reference in New Issue
Block a user