fix nl-be

This commit is contained in:
HolgerHatGarKeineNode
2023-12-08 17:45:29 +01:00
parent 6fd3e534ac
commit 46ed688373
2 changed files with 11 additions and 0 deletions

View File

@@ -74,6 +74,10 @@ class Header extends Component
public function updatedL($value)
{
if ($value === 'nl-be') {
$value = 'nl';
}
Cookie::queue('lang', $value, 60 * 24 * 365);
return redirect(request()->header('Referer'));

View File

@@ -26,6 +26,9 @@ class Welcome extends Component
public function mount()
{
$this->l = Cookie::get('lang') ?: config('app.locale');
if ($this->l === 'nl-be') {
$this->l = 'nl';
}
$this->c = Cookie::get('country') ?: config('app.country');
Cookie::queue('lang', $this->l, 60 * 24 * 365);
Cookie::queue('country', $this->c, 60 * 24 * 365);
@@ -45,6 +48,10 @@ class Welcome extends Component
$l = $this->l;
}
if ($this->l === 'nl-be') {
$this->l = 'nl';
}
Cookie::queue('lang', $this->l, 60 * 24 * 365);
Cookie::queue('country', $this->c, 60 * 24 * 365);