Browse Source

Merge branch 'master' of git.yiisoft.com:yii2 into console-color

tags/2.0.0-beta
Qiang Xue 12 years ago
parent
commit
328bb2c0ac
  1. 8
      framework/db/dao/QueryBuilder.php

8
framework/db/dao/QueryBuilder.php

@ -565,9 +565,7 @@ class QueryBuilder extends \yii\base\Object
list($column, $values) = $operands;
if (!is_array($values)) {
$values = array($values);
}
$values = (array)$values;
if ($values === array() || $column === array()) {
return $operator === 'in' ? '0=1' : '';
@ -633,9 +631,7 @@ class QueryBuilder extends \yii\base\Object
list($column, $values) = $operands;
if (!is_array($values)) {
$values = array($values);
}
$values = (array)$values;
if ($values === array()) {
return $operator === 'LIKE' || $operator === 'OR LIKE' ? '0=1' : '';

Loading…
Cancel
Save