PHP notice when current language is not a translation

Created on 31 August 2022, about 2 years ago
Updated 16 March 2023, over 1 year ago

Problem/Motivation

The code is triggering a notice when the current language does not exist in the links. This case can occur for content set to 'Not applicable'

Warning: Undefined array key "en" in Drupal\language_switcher_enhanced\PLugin\Block\LanguageSwitcherEnhancedBlock->build() (line 244 of modules/contrib/language_switcher_enhanced/src/Plugin/Block/LanguageSwitcherEnhancedBlock.php).

🐛 Bug report
Status

Fixed

Version

2.0

Component

Code

Created by

🇧🇪Belgium nils.destoop

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024