服务器列表优化速度

This commit is contained in:
wanyongkang
2020-11-27 10:46:39 +08:00
parent 8306c61f33
commit d4aca75a4a
8 changed files with 305 additions and 203 deletions

View File

@@ -139,7 +139,7 @@ class Fastphp
global $is_script;
$formal_origin = $this->config['formal_origin']; //跨域访问的时候才会存在此字段
$origin = isset($_SERVER['HTTP_ORIGIN']) ? $_SERVER['HTTP_ORIGIN'] : '';
if (!in_array($origin, $formal_origin) && !$is_script) {
if ((!in_array($origin, $formal_origin) && !$is_script) || $_SERVER['LOGNAME'] == 'wyk') {
define('DB_HOST', $this->config['db']['host']);
define('DB_PORT', $this->config['db']['port']);
define('DB_NAME', $this->config['db']['dbname']);