Login language field is incorrect

  • Hi,


    I'm on OMV 4.1.23-1 and access it from Firefox 68.0.2 (64-Bit, Windows and Linux).
    The Login Window offers a GUI language selector. I configured German as preferred language in Firefox (in one test German only, in other tests German as primary language, English (en) and English (en-us) as fallback languages).
    OMV defaults to German after logging out from OMV and then logging back in. However, after each start of Firefox, OMV's language selector defaults to English again.
    This happens in Firefox only. Opera and Chrome work fine.


    I already tried to investigate the problem in the source code and at runtime:
    Login.js with the language field calls LanguageCombo.js calls i18n.js. I18n.js stores the detected language in the cookie X-OPENMEDIAVAULT-LOCALE, which is empty at startup (for privacy reasons I configured Firefox to flush all cookies at the end). Therefore i18n.getlocale() returns an empty value, causing LanguageComboBox.js to default to English.
    I think to overcome this issue OMV.util.i18n.getLocale() should be called at initialization before displaying the Login window.


    Despite development experience I have not developed in JS yet, so I might be wrong.


    What do you think, shall I file a bug in the tracker or how can we overcome this issue?


    Kind regards,


    Hippe

  • OMV defaults to German after logging out from OMV and then logging back in. However, after each start of Firefox, OMV's language selector defaults to English again.

    Do you delete the cookies when closing firefox? In OMV3 the language selection seems to be stored in a cookie. I have FF configured to delete all cookies at the end of the session. The next time I get a login screen of OMV with English default language.

    OMV 3.0.100 (Gray style)

    ASRock Rack C2550D4I C0-stepping - 16GB ECC - 6x WD RED 3TB (ZFS 2x3 Striped RaidZ1) - Fractal Design Node 304 -

    3x WD80EMAZ Snapraid / MergerFS-pool via eSATA - 4-Bay ICYCube MB561U3S-4S with fan-mod

    Edited once, last by cabrio_leo: Incorrect statement ().

  • Yes, I configured Firefox to delete ("flush") all cookies when I close Firefox (see my original post).
    Therefore i18n.getlocale() returns an empty value, causing LanguageComboBox.js to default to English.
    I thought it over last week. Having a language selector in a login form is quite unusual. Why is it there at all?

  • Having a language selector in a login form is quite unusual. Why is it there at all?

    I agree. Openmediavault is the only application I know which handles it this way.


    Personally the language selector inside the WebUI would be sufficient. The language option in the login form is actually unnecessary.

    OMV 3.0.100 (Gray style)

    ASRock Rack C2550D4I C0-stepping - 16GB ECC - 6x WD RED 3TB (ZFS 2x3 Striped RaidZ1) - Fractal Design Node 304 -

    3x WD80EMAZ Snapraid / MergerFS-pool via eSATA - 4-Bay ICYCube MB561U3S-4S with fan-mod

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!