- Fixed error thrown on optional routes which arguments were not all fullfield
This commit is contained in:
parent
be65d45b41
commit
386e0aa448
|
@ -268,7 +268,7 @@ PATTERN;
|
||||||
if ($default ?? false) {
|
if ($default ?? false) {
|
||||||
$value = $default;
|
$value = $default;
|
||||||
}
|
}
|
||||||
elseif ($this->enforceExistingArguments) {dump($routeParam);
|
elseif ( strpos($route, "[{$matches[0][0]}]") !== false && $this->enforceExistingArguments) {
|
||||||
throw new \RuntimeException(sprintf("Error while preparing route %s : could not match variable '%s' into given arguments ( %s ) from %s::%s", $route, $variable, json_encode($arguments), $routeParam['class'], $routeParam['classMethod']));
|
throw new \RuntimeException(sprintf("Error while preparing route %s : could not match variable '%s' into given arguments ( %s ) from %s::%s", $route, $variable, json_encode($arguments), $routeParam['class'], $routeParam['classMethod']));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue