Skip to content

JS Locales cache not discriminated by language #21581

@cconard96

Description

@cconard96

Code of Conduct

  • I agree to follow this project's Code of Conduct

Is there an existing issue for this?

  • I have searched the existing issues

Version

11.0/bugfixes (maybe 10.0 too)

Bug description

When in production env, the translated strings sent to the browser for translations done in JS code are cachable. However, the front/locale.php cache key used is the same as any other asset which only relies on GLPI version, hostname and GLPI_ROOT. This means if you switch language, all translations done by JS will remain in the previous language until the cache expires or the cache is cleared for another reason.

Relevant log output

Page URL

No response

Steps To reproduce

No response

Your GLPI setup information

No response

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions