Fixed wrong Grav param separator when using Route class

This commit is contained in:
Matias Griese
2019-10-03 10:56:05 +03:00
parent 9259c2f660
commit a75c0cbe62
3 changed files with 15 additions and 1 deletions

View File

@@ -6,6 +6,7 @@
* Flex: Removed extra exists check when creating object (messes up "non-existing" pages)
* Support customizable null character replacement in `CSVFormatter::decode()`
1. [](#bugfix)
* Fixed wrong Grav param separator when using `Route` class
# v1.7.0-beta.9
## 09/26/2019
@@ -129,7 +130,6 @@
* Added support for [Clockwork](https://underground.works/clockwork) developer tools (now default debugger)
* Added support for [Tideways XHProf](https://github.com/tideways/php-xhprof-extension) PHP Extension for profiling method calls
* Added Twig profiling for Clockwork debugger
* Updated Symfony Components to 4.3
* Added support for Twig 2.11 (compatible with Twig 1.40+)
* Optimization: Initialize debugbar only after the configuration has been loaded
* Optimization: Combine some early Grav processors into a single one

View File

@@ -207,6 +207,7 @@ class Uri
RouteFactory::setRoot($this->root_path);
RouteFactory::setLanguage($language->getLanguageURLPrefix());
RouteFactory::setParamValueDelimiter($config->get('system.param_sep'));
}
/**

View File

@@ -215,6 +215,10 @@ class Route
return $new;
}
/**
* @param string $language
* @return Route
*/
public function withLanguage($language)
{
$new = $this->copy();
@@ -267,11 +271,17 @@ class Route
return $this->withParam('queryParams', $param, $value);
}
/**
* @return Route
*/
public function withoutParams()
{
return $this->withoutGravParams()->withoutQueryParams();
}
/**
* @return Route
*/
public function withoutGravParams()
{
$new = $this->copy();
@@ -280,6 +290,9 @@ class Route
return $new;
}
/**
* @return Route
*/
public function withoutQueryParams()
{
$new = $this->copy();