diff --git a/module/common/model.php b/module/common/model.php index d5619f4c28..b9f8b4c613 100644 --- a/module/common/model.php +++ b/module/common/model.php @@ -402,7 +402,11 @@ class commonModel extends model $this->config->system = isset($config['system']) ? $config['system'] : array(); $this->config->personal = isset($config[$account]) ? $config[$account] : array(); - $this->commonTao->updateDBWebRoot($this->config->system); + /* Web root cannot be changed by api request. */ + if(!$this->app->apiVersion) + { + $this->commonTao->updateDBWebRoot($this->config->system); + } /* Override the items defined in config/config.php and config/my.php. */ if(isset($this->config->system->common)) $this->app->mergeConfig($this->config->system->common, 'common');