diff --git a/lib/Cake/Model/Model.php b/lib/Cake/Model/Model.php index 746b2e03c..63fea7f1e 100644 --- a/lib/Cake/Model/Model.php +++ b/lib/Cake/Model/Model.php @@ -2106,7 +2106,7 @@ class Model extends Object implements CakeEventListener { protected function _prepareUpdateFields($data) { $foreignKeys = array(); foreach ($this->belongsTo as $assoc => $info) { - if ($info['counterCache']) { + if (isset($info['counterCache']) && $info['counterCache']) { $foreignKeys[$assoc] = $info['foreignKey']; } }