mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
forget old lang cookies
This commit is contained in:
@@ -17,7 +17,11 @@ class SetTimezoneMiddleware
|
||||
*/
|
||||
public function handle(Request $request, Closure $next): Response
|
||||
{
|
||||
App::setLocale(Cookie::get('lang') ?: config('app.locale'));
|
||||
$locale = Cookie::get('lang') ?: config('app.locale');
|
||||
if (str($locale)->contains('ey')) {
|
||||
$locale = 'de';
|
||||
}
|
||||
App::setLocale($locale);
|
||||
if ($request->country) {
|
||||
config([
|
||||
'app.country' => $request->country,
|
||||
|
||||
Reference in New Issue
Block a user