Skip to content

Commit

Permalink
Merge pull request #273 from symfony-cmf/cleanup-typing
Browse files Browse the repository at this point in the history
restricted some interfaces too much
  • Loading branch information
dbu authored Feb 7, 2022
2 parents 791b332 + 9724a91 commit d1fc412
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/RedirectRouteInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ interface RedirectRouteInterface extends RouteObjectInterface
*
* If this is non-empty, the other methods won't be used.
*
* @return string target absolute uri
* @return string|null target absolute uri
*/
public function getUri(): string;
public function getUri(): ?string;

/**
* Get the target route document this route redirects to.
Expand All @@ -62,7 +62,7 @@ public function getRouteTarget(): ?SymfonyRoute;
* Get the name of the target route for working with the symfony standard
* router.
*/
public function getRouteName(): string;
public function getRouteName(): ?string;

/**
* Whether this should be a permanent or temporary redirect.
Expand Down
2 changes: 1 addition & 1 deletion src/RouteProviderInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,5 +79,5 @@ public function getRouteByName(string $name): SymfonyRoute;
*
* @return SymfonyRoute[] Iterable list with the keys being the names from the $names array
*/
public function getRoutesByNames(?array $names): array;
public function getRoutesByNames(?array $names = null): iterable;
}
1 change: 0 additions & 1 deletion tests/Unit/Routing/DynamicRouterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@

class DynamicRouterTest extends TestCase
{

/**
* @var UrlMatcherInterface&MockObject
*/
Expand Down

0 comments on commit d1fc412

Please sign in to comment.