Bugfixes and optimizations

- Fixed `hasParam` not working returning expected value in `Url` class.
- Chained the remaining methods in the `Url` class.
- Simplified `removeParam` method in `Url` class.
- Added new `removeParams` method to `Url` class for removal of multiple params.
This commit is contained in:
Simon Sessingø
2018-04-01 03:02:21 +02:00
parent 53f0b7d8e2
commit 1dc88d23e1
3 changed files with 142 additions and 138 deletions
+1 -1
View File
@@ -447,7 +447,7 @@ class SimpleRouter
* @param array|null $getParams
* @return Url
*/
public static function getUrl(?string $name = null, $parameters = null, $getParams = null): Url
public static function getUrl(?string $name = null, $parameters = null, ?array $getParams = null): Url
{
try {
return static::router()->getUrl($name, $parameters, $getParams);