adding a note about language setter in successful login event

This commit is contained in:
Brian 2022-07-19 14:11:09 -06:00
parent 64454ddee7
commit 2b13367970
Signed by: brian
GPG Key ID: DE1A5390A3B84CD8

View File

@ -29,6 +29,10 @@ class SuccessfulLogin
public function handle(Login $event): void public function handle(Login $event): void
{ {
Session::put('timezone_name', $event->user->timezone_name); Session::put('timezone_name', $event->user->timezone_name);
// TODO: this may need to be reworked so that the language is stored
// in a cookie and attempted to be retrieved from there
// first before pulling from the database.
Session::put('language', $event->user->language->locale); Session::put('language', $event->user->language->locale);
// Optionally log the info // Optionally log the info