Permalink
Browse files

Remove duplicated reference for behaviors in ClassRegistry

The 2nd key in the registry was to support persistModel which has long
since been removed. With this registry key not being used it can be
removed with reasonable safety.

Fixes #2306
  • Loading branch information...
markstory committed Nov 11, 2013
1 parent 9d18a5d commit 1f5d1eee988e8becddc2f3bd20ac43a37fc68daf
Showing with 0 additions and 3 deletions.
  1. +0 −3 lib/Cake/Model/BehaviorCollection.php
@@ -132,9 +132,6 @@ public function load($behavior, $config = array()) {
} else {
$this->_loaded[$alias] = new $class();
ClassRegistry::addObject($class, $this->_loaded[$alias]);
if (!empty($plugin)) {
ClassRegistry::addObject($plugin . '.' . $class, $this->_loaded[$alias]);
}
}
} elseif (isset($this->_loaded[$alias]->settings) && isset($this->_loaded[$alias]->settings[$this->modelName])) {
if ($config !== null && $config !== false) {

0 comments on commit 1f5d1ee

Please sign in to comment.