Skip to content

Commit 204c3ae

Browse files
jargoudJérémy ARGOUD
andauthored
Handle locales mapping when loading caches routes (#763)
Co-authored-by: Jérémy ARGOUD <jargoud@webqam.fr>
1 parent 1a16ee7 commit 204c3ae

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Mcamara/LaravelLocalization/Traits/LoadsTranslatedCachedRoutes.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,9 @@ protected function loadCachedRoutes()
2424

2525
// compute $locale from url.
2626
// It is null if url does not contain locale.
27-
$locale = $localization->setLocale();
27+
$locale = $localization->getInversedLocaleFromMapping(
28+
$localization->setLocale()
29+
);
2830

2931
$localeKeys = $localization->getSupportedLanguagesKeys();
3032

0 commit comments

Comments
 (0)