Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Language conditions do not match the expected context.
Drupal\notification_message\EventSubscriber\getContextsFromRepository() returns a Language context with the key of "language_interface"
Whereas Drupal\notification_message\Entity->getRequiredContexts() returns a key of "language"
.
This mismatch causes the context condition to be excluded from the results of Drupal\notification_message\Entity->extractRequiredContexts()
Steps to Reproduce
- Configure a site for multiple languages
- Create a notification message and configure it to show on the page and for the English language
- Ensure "Require all Conditions" is checked and the message is published
- View the home page
Expected Result
The Notification Message appears
Observed Result
No notification message appears
Comment | File | Size | Author |
---|---|---|---|
#3 | 3119965-3.notification_message.Language-conditions-do-not-match-contexts.patch | 1.44 KB | pixelwhip |
Comments
Comment #2
pixelwhip CreditAttribution: pixelwhip at Aten Design Group commentedComment #3
pixelwhip CreditAttribution: pixelwhip at Aten Design Group commentedPatch attached!
Comment #5
droath CreditAttribution: droath at Aten Design Group commentedComment #6
droath CreditAttribution: droath at Aten Design Group commented