We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e5e78cb commit 2630df3Copy full SHA for 2630df3
src/Translatable.php
@@ -33,10 +33,13 @@ public function getLocaleFromRequest(): string {
33
34
if (count($params) > 0) {
35
$locale = $params[0];
36
- if ($this->checkLocaleInSupportedLocales($locale)) return $locale;
+
37
+ if ($this->checkLocaleInSupportedLocales($locale)) {
38
+ return $locale;
39
+ }
40
}
41
- return config('translatable.fallback_locale');
42
+ return app()->getLocale() ?? config('translatable.fallback_locale');
43
44
45
/**
0 commit comments