mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
fixed shell dispatcher failed unit test
This commit is contained in:
parent
92e380737d
commit
7ffa7acea6
1 changed files with 2 additions and 2 deletions
|
@ -315,14 +315,14 @@ class ShellDispatcher {
|
||||||
} elseif (strpos($params['app'], '/')) {
|
} elseif (strpos($params['app'], '/')) {
|
||||||
$params['root'] .= '/' . dirname($params['app']);
|
$params['root'] .= '/' . dirname($params['app']);
|
||||||
}
|
}
|
||||||
|
$isWindowsAppPath = $this->_isWindowsPath($params['app']);
|
||||||
$params['app'] = basename($params['app']);
|
$params['app'] = basename($params['app']);
|
||||||
$params['working'] = rtrim($params['root'], '/');
|
$params['working'] = rtrim($params['root'], '/');
|
||||||
if (!$isWin || !preg_match('/^[A-Z]:$/i', $params['app'])) {
|
if (!$isWin || !preg_match('/^[A-Z]:$/i', $params['app'])) {
|
||||||
$params['working'] .= '/' . $params['app'];
|
$params['working'] .= '/' . $params['app'];
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($this->_isWindowsPath($params['app']) || !empty($isWin)) {
|
if ($isWindowsAppPath || !empty($isWin)) {
|
||||||
$params = str_replace('/', '\\', $params);
|
$params = str_replace('/', '\\', $params);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue