Bundle/I18nBundle/Subscriber/LocaleSubscriber.php
public function onLogin(InteractiveLoginEvent $event)
    {
        $user = $event->getAuthenticationToken()->getUser();

        if ($user instanceof VictoireUserInterface) {
            // set the victoireLocale
            $event->getRequest()->getSession()->set('victoire_locale', $user->getLocale());
        }
    }
public function onLogin(InteractiveLoginEvent $event)
    {
        $user = $event->getAuthenticationToken()->getUser();

        if ($user instanceof VictoireUserInterface) {
            // set the victoireLocale
            $event->getRequest()->getSession()->set('victoire_locale', $user->getLocale());
        }
    }
public function onLogin ( InteractiveLoginEvent $ event ) { $ user = $ event -> getAuthenticationToken ( ) -> getUser ( ) ; if ( $ user instanceof VictoireUserInterface ) { // set the victoireLocale $ event -> getRequest ( ) -> getSession ( ) -> set ( 'victoire_locale' , $ user -> getLocale ( ) ) ; } }
This method will be called on user login in order to set the victoire locale.

@param InteractiveLoginEvent $event
This method will be called on user login in order to set the victoire locale .