Current Language id() returns languageCode-CountryCode but we need only language code.

Created on 24 October 2023, about 1 year ago

Current Language id() returns languageCode-CountryCode but we need only language code.

In a module the line \Drupal::languageManager()->getCurrentLanguage()->getId() returns languageCode-CountryCode (hu-HU) and inserts it into 'data-culture' attributes, and it cause the issue, and the banner shows only on default language instead of current.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡¦Ukraine vorona olya

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024