Skip to content

Commit d17b3bf

Browse files
fixed phpstan name LoadableRoute function #18
1 parent e2e4c4a commit d17b3bf

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/Pecee/SimpleRouter/Route/ILoadableRoute.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,16 @@ public function setUrl(string $url): self;
4646
*/
4747
public function prependUrl(string $url): self;
4848

49+
/**
50+
* Sets the router name, which makes it easier to obtain the url or router at a later point.
51+
* Alias for LoadableRoute::setName().
52+
*
53+
* @param string|array $name
54+
* @return static
55+
* @see LoadableRoute::setName()
56+
*/
57+
public function name(array|string $name): self;
58+
4959
/**
5060
* Returns the provided name for the router.
5161
*

0 commit comments

Comments
 (0)