From cc2cac58d298e2d4caef393baa373229cc505320 Mon Sep 17 00:00:00 2001 From: Alexander Makarov Date: Sat, 12 May 2018 14:17:59 +0300 Subject: [PATCH] Fixed bad instnaceof check in `yii\db\Schema::getTableMetadata()` --- framework/CHANGELOG.md | 1 + framework/db/Schema.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/framework/CHANGELOG.md b/framework/CHANGELOG.md index 65f5dd39c0..e34308e83b 100644 --- a/framework/CHANGELOG.md +++ b/framework/CHANGELOG.md @@ -22,6 +22,7 @@ Yii Framework 2 Change Log - Bug #16245: Fixed `__isset()` in `BaseActiveRecord` not catching errors (sammousa) - Enh #16191: Enhanced `yii\helpers\Inflector` to work correctly with UTF-8 (silverfire) +- Bug: Fixed bad instnaceof check in `yii\db\Schema::getTableMetadata()` (samdark) 2.0.15.1 March 21, 2018 diff --git a/framework/db/Schema.php b/framework/db/Schema.php index 30cdd82fc7..ced2e6d453 100644 --- a/framework/db/Schema.php +++ b/framework/db/Schema.php @@ -732,7 +732,7 @@ abstract class Schema extends BaseObject $cache = null; if ($this->db->enableSchemaCache && !in_array($name, $this->db->schemaCacheExclude, true)) { $schemaCache = is_string($this->db->schemaCache) ? Yii::$app->get($this->db->schemaCache, false) : $this->db->schemaCache; - if ($schemaCache instanceof Cache) { + if ($schemaCache instanceof CacheInterface) { $cache = $schemaCache; } }