Skip to content

Commit

Permalink
moving path configuration to App class
Browse files Browse the repository at this point in the history
  • Loading branch information
gwoo committed Jun 7, 2009
1 parent f84ed69 commit 24d78dd
Show file tree
Hide file tree
Showing 28 changed files with 538 additions and 526 deletions.
4 changes: 2 additions & 2 deletions cake/console/cake.php
Expand Up @@ -198,7 +198,7 @@ function _initEnvironment() {
*/
function __buildPaths() {
$paths = array();
$pluginPaths = Configure::read('pluginPaths');
$pluginPaths = App::path('plugins');
if (!class_exists('Folder')) {
require LIBS . 'folder.php';
}
Expand Down Expand Up @@ -259,7 +259,7 @@ function __bootstrap() {
Configure::getInstance(file_exists(CONFIGS . 'bootstrap.php'));

if (!file_exists(APP_PATH . 'config' . DS . 'core.php')) {
include_once CORE_PATH . 'cake' . DS . 'console' . DS . 'libs' . DS . 'templates' . DS . 'skel' . DS . 'config' . DS . 'core.php';
include_once CORE_PATH . 'cake' . DS . 'console' . DS . 'templates' . DS . 'skel' . DS . 'config' . DS . 'core.php';
Configure::buildPaths(array());
}

Expand Down
2 changes: 1 addition & 1 deletion cake/console/libs/testsuite.php
Expand Up @@ -316,7 +316,7 @@ function __findFolderByCategory($category) {
} else {
$scoredCategory = Inflector::underscore($category);
$folder = APP . 'plugins' . DS . $scoredCategory . DS;
$pluginPaths = Configure::read('pluginPaths');
$pluginPaths = App::path('plugins');
foreach ($pluginPaths as $path) {
if (file_exists($path . $scoredCategory . DS . 'tests')) {
$folder = $path . $scoredCategory . DS . 'tests';
Expand Down
2 changes: 1 addition & 1 deletion cake/dispatcher.php
Expand Up @@ -620,7 +620,7 @@ function cached($url) {
if ($pos > 0) {
$plugin = substr($url, 0, $pos - 1);
$url = str_replace($plugin . '/', '', $url);
$pluginPaths = Configure::read('pluginPaths');
$pluginPaths = App::path('plugins');
$count = count($pluginPaths);
for ($i = 0; $i < $count; $i++) {
$paths[] = $pluginPaths[$i] . $plugin . DS . 'vendors' . DS;
Expand Down

0 comments on commit 24d78dd

Please sign in to comment.