改进Connection类的connect方法

This commit is contained in:
thinkphp
2016-08-09 12:16:36 +08:00
parent 1a089223ea
commit 6a2fda25de
2 changed files with 3 additions and 1 deletions

View File

@@ -57,5 +57,5 @@ if (is_file(ROOT_PATH . 'env' . EXT)) {
// 注册错误和异常处理机制
\think\Error::register();
// 加载模式配置文件
// 加载惯例配置文件
\think\Config::set(include THINK_PATH . 'convention' . EXT);

View File

@@ -255,6 +255,8 @@ abstract class Connection
if (!isset($this->links[$linkNum])) {
if (!$config) {
$config = $this->config;
} else {
$config = array_merge($this->config, $config);
}
// 连接参数
if (isset($config['params']) && is_array($config['params'])) {