Skip to content

Commit

Permalink
Merge pull request #11773 from nanaya/locale-reload-full
Browse files Browse the repository at this point in the history
Force browser page refresh on locale change
  • Loading branch information
notbakaneko authored Jan 14, 2025
2 parents b412e07 + 333f638 commit 8b77760
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion app/Http/Controllers/HomeController.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ public function setLocale()
]);
}

return ext_view('layout.ujs-reload', [], 'js')
return ext_view('layout.ujs_full_reload', [], 'js')
->withCookie(cookie()->forever('locale', $newLocale));
}

Expand Down
5 changes: 5 additions & 0 deletions resources/views/layout/ujs_full_reload.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{{--
Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the GNU Affero General Public License v3.0.
See the LICENCE file in the repository root for full licence text.
--}}
window.location.reload();

0 comments on commit 8b77760

Please sign in to comment.