Moving more clases to the new layout while trying to make controller related classes load

This commit is contained in:
José Lorenzo Rodríguez 2010-12-04 02:45:22 -04:30
parent b4387d2f51
commit fbbb5c9337
11 changed files with 3 additions and 8 deletions

View file

@ -16,7 +16,7 @@
* @since CakePHP(tm) v 2.0
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
App::uses('ObjectCollection', 'Core');
App::uses('ObjectCollection', 'Utility');
class ComponentCollection extends ObjectCollection {
@ -70,13 +70,8 @@ class ComponentCollection extends ObjectCollection {
return $this->_loaded[$name];
}
$componentClass = $name . 'Component';
App::uses($componentClass, 'Controller/Component');
if (!class_exists($componentClass)) {
if (!App::import('Component', $component)) {
throw new MissingComponentFileException(array(
'file' => Inflector::underscore($component) . '.php',
'class' => $componentClass
));
}
if (!class_exists($componentClass)) {
throw new MissingComponentFileException(array(
'file' => Inflector::underscore($component) . '.php',

View file

@ -21,7 +21,7 @@
/**
* Include files
*/
App::uses('CakeResponse', 'Core');
App::uses('CakeResponse', 'Network');
App::uses('ClassRegistry', 'Core');
App::uses('ComponentCollection', 'Controller');
App::uses('View', 'View');