改进数组查询条件中的null查询

This commit is contained in:
thinkphp
2017-08-10 10:34:23 +08:00
parent 62a6a0270b
commit 2a07b7dbb8

View File

@@ -302,7 +302,7 @@ abstract class Builder
// 查询规则和条件
if (!is_array($val)) {
$val = ['=', $val];
$val = is_null($val) ? ['null', ''] : ['=', $val];
}
list($exp, $value) = $val;