Skip to content

Commit

Permalink
Merge pull request #119 from bobdenotter/patch-1
Browse files Browse the repository at this point in the history
For when _locale is passed in, but empty / false. Fixes a quirk in Bolt 3.3
  • Loading branch information
SahAssar authored Jun 6, 2017
2 parents dedaee5 + 5d2bea2 commit bf9db52
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Routing/LocalizedUrlGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function __construct(UrlGeneratorInterface $wrapped, Application $app)
*/
public function generate($name, $parameters = [], $referenceType = UrlGeneratorInterface::ABSOLUTE_PATH)
{
if (!isset($parameters['_locale']) && $name !== "thumb") {
if (empty($parameters['_locale']) && $name !== "thumb") {
$parameters['_locale'] = $this->app['translate.slug'];
}

Expand Down

0 comments on commit bf9db52

Please sign in to comment.