mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-26 03:30:32 +08:00
Fixed condition building for booleans
This commit is contained in:
@@ -268,6 +268,9 @@ EOF;
|
||||
if (is_array($value)) { // IN condition
|
||||
$parts[] = $this->buildInCondition('in', [$column, $value], $columns);
|
||||
} else {
|
||||
if (is_bool($value)) {
|
||||
$value = (int)$value;
|
||||
}
|
||||
$column = $this->addColumn($column, $columns);
|
||||
if ($value === null) {
|
||||
$parts[] = "$column==nil";
|
||||
|
||||
@@ -161,12 +161,6 @@ class ActiveRecordTest extends RedisTestCase
|
||||
$this->markTestSkipped('Redis does not store/find null values correctly.');
|
||||
}
|
||||
|
||||
public function testBooleanAttribute()
|
||||
{
|
||||
// https://github.com/yiisoft/yii2/issues/1311
|
||||
$this->markTestSkipped('Redis does not store/find boolean values correctly.');
|
||||
}
|
||||
|
||||
public function testFindEagerViaRelationPreserveOrder()
|
||||
{
|
||||
$this->markTestSkipped('Redis does not support orderBy.');
|
||||
|
||||
Reference in New Issue
Block a user