[BUGFIX] Fixed Exceptions due to route null value.

This commit is contained in:
Simon Sessingø
2015-10-30 02:27:44 +01:00
parent a2edc1504c
commit 649ed28a91
+2 -2
View File
@@ -253,7 +253,7 @@ class RouterBase {
throw new \InvalidArgumentException('Invalid type for getParams. Must be array or null');
}
if($controller === null && $parameters === null) {
if($controller === null && $parameters === null && $this->loadedRoute !== null) {
return $this->processUrl($this->loadedRoute, null, $getParams);
}
@@ -295,7 +295,7 @@ class RouterBase {
$method = $tmp[1];
}
if($controller === $c) {
if($controller === $c && $route !== null) {
return $this->processUrl($route, $method, $parameters, $getParams);
}
}