mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Unused variables in Routing removed
This commit is contained in:
parent
ad73c7038c
commit
3c9cb3b97d
3 changed files with 4 additions and 5 deletions
|
@ -299,7 +299,6 @@ class Dispatcher {
|
||||||
include WWW_ROOT . DS . $filters['js'];
|
include WWW_ROOT . DS . $filters['js'];
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
$controller = null;
|
|
||||||
$pathSegments = explode('.', $url);
|
$pathSegments = explode('.', $url);
|
||||||
$ext = array_pop($pathSegments);
|
$ext = array_pop($pathSegments);
|
||||||
$parts = explode('/', $url);
|
$parts = explode('/', $url);
|
||||||
|
|
|
@ -399,7 +399,7 @@ class CakeRoute {
|
||||||
$greedyNamed = $namedConfig['greedyNamed'];
|
$greedyNamed = $namedConfig['greedyNamed'];
|
||||||
$allowedNamedParams = $namedConfig['rules'];
|
$allowedNamedParams = $namedConfig['rules'];
|
||||||
|
|
||||||
$named = $pass = $_query = array();
|
$named = $pass = array();
|
||||||
|
|
||||||
foreach ($url as $key => $value) {
|
foreach ($url as $key => $value) {
|
||||||
|
|
||||||
|
|
|
@ -487,7 +487,7 @@ class Router {
|
||||||
'named' => array()
|
'named' => array()
|
||||||
);
|
);
|
||||||
|
|
||||||
$r = $ext = null;
|
$ext = null;
|
||||||
|
|
||||||
if ($url && strpos($url, '/') !== 0) {
|
if ($url && strpos($url, '/') !== 0) {
|
||||||
$url = '/' . $url;
|
$url = '/' . $url;
|
||||||
|
@ -771,7 +771,7 @@ class Router {
|
||||||
* @return string Full translated URL with base path.
|
* @return string Full translated URL with base path.
|
||||||
*/
|
*/
|
||||||
public static function url($url = null, $full = false) {
|
public static function url($url = null, $full = false) {
|
||||||
$defaults = $params = array('plugin' => null, 'controller' => null, 'action' => 'index');
|
$params = array('plugin' => null, 'controller' => null, 'action' => 'index');
|
||||||
|
|
||||||
if (is_bool($full)) {
|
if (is_bool($full)) {
|
||||||
$escape = false;
|
$escape = false;
|
||||||
|
@ -792,7 +792,7 @@ class Router {
|
||||||
}
|
}
|
||||||
|
|
||||||
$base = $path['base'];
|
$base = $path['base'];
|
||||||
$extension = $output = $mapped = $q = $frag = null;
|
$extension = $output = $q = $frag = null;
|
||||||
|
|
||||||
if (empty($url)) {
|
if (empty($url)) {
|
||||||
$output = isset($path['here']) ? $path['here'] : '/';
|
$output = isset($path['here']) ? $path['here'] : '/';
|
||||||
|
|
Loading…
Reference in a new issue