|
|
@@ -50,11 +50,18 @@ class CakePlugin {
|
|
|
return;
|
|
|
}
|
|
|
$config += array('bootstrap' => false, 'routes' => false);
|
|
|
- $underscored = Inflector::underscore($plugin);
|
|
|
if (empty($config['path'])) {
|
|
|
foreach (App::path('plugins') as $path) {
|
|
|
+ if (is_dir($path . $plugin)) {
|
|
|
+ self::$_plugins[$plugin] = $config + array('path' => $path . $plugin . DS);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+
|
|
|
+ //Backwards compatibility to make easier to migrate to 2.0
|
|
|
+ $underscored = Inflector::underscore($plugin);
|
|
|
if (is_dir($path . $underscored)) {
|
|
|
self::$_plugins[$plugin] = $config + array('path' => $path . $underscored . DS);
|
|
|
+ break;
|
|
|
}
|
|
|
}
|
|
|
} else {
|