Skip to content

Commit

Permalink
Merge branch 'master' of github.com:dannyvankooten/AltoRouter
Browse files Browse the repository at this point in the history
  • Loading branch information
dannyvankooten committed Jan 5, 2025
2 parents 9d62094 + bc6b911 commit 41fcec6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions AltoRouter.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public function addMatchTypes(array $matchTypes)
* @param string $name Optional name of this route. Supply if you want to reverse route this url in your application.
* @throws Exception
*/
public function map(string $method, string $route, $target, string $name = null)
public function map(string $method, string $route, $target, ?string $name = null)
{

$this->routes[] = [$method, $route, $target, $name];
Expand Down Expand Up @@ -184,7 +184,7 @@ public function generate(string $routeName, array $params = []): string
* @param string $requestMethod
* @return array|boolean Array with route information on success, false on failure (no match).
*/
public function match(string $requestUrl = null, string $requestMethod = null)
public function match(?string $requestUrl = null, ?string $requestMethod = null)
{

$params = [];
Expand Down

0 comments on commit 41fcec6

Please sign in to comment.