From 8ef30344825686e9bdce78caccc87c0b75a6cf2e Mon Sep 17 00:00:00 2001 From: Sam Mousa Date: Sat, 24 Nov 2012 12:22:17 +0100 Subject: [PATCH] Added the table name to the cacheKey used by DboSource::fields. #3394 --- lib/Cake/Model/Datasource/DboSource.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Cake/Model/Datasource/DboSource.php b/lib/Cake/Model/Datasource/DboSource.php index 623b7a01f93..8cf997a78d0 100644 --- a/lib/Cake/Model/Datasource/DboSource.php +++ b/lib/Cake/Model/Datasource/DboSource.php @@ -2282,7 +2282,8 @@ public function fields(Model $model, $alias = null, $fields = array(), $quote = $virtualFields, $fields, $quote, - ConnectionManager::getSourceName($this) + ConnectionManager::getSourceName($this), + $model->table ); $cacheKey = md5(serialize($cacheKey)); if ($return = $this->cacheMethod(__FUNCTION__, $cacheKey)) {