Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 292268

Messenger service can't set messages super early and loses reference to flashbag reference on rebuild

$
0
0

Problem/Motivation

When a new module is installed (kernel rebuild) the reference between the messenger service and the flashbag is reset. Any messenger service instantiated or any messages set before the this will be lost. See #474684-141: Allow themes to declare dependencies on modules

Also messages set in the early bootstrap are lost as well. Both of these are a regression introduced by #2760167: Add \Drupal\Core\Messenger\Messenger

Proposed resolution

Instead of injecting session.flash_bag into the messenger inject session so that when the messenger service adds a message the session is started.

Remaining tasks

User interface changes

None

API changes

In \Drupal\Core\Messenger\Messenger::__construct() change FlashBagInterface to SessionInterface

Data model changes

None


Viewing all articles
Browse latest Browse all 292268

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>