In #2505497: Support render arrays for drupal_set_message() we adding more tests for SafeStrings in dsm() plus we removed the string cast. This issue we remove the entire safe storing in the message array and use SafeString::create instead so we can remove the SafeMarkup::set() in drupal_get_messages()
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 2546176.2.patch | 6.47 KB | alexpott |
Comments
Comment #2
alexpottLess loops and less SafeMarkup::set() - I like it.
Comment #3
alexpottComment #4
xjmThis is great, and also makes #2505497: Support render arrays for drupal_set_message() potentially cleaner.
I think the only potential concern is with storing objects in
$_SESSIONas per @catch's concerns in #2505497: Support render arrays for drupal_set_message(). However, a SafeString object is definitely a much smaller/safer thing to put there than an entire render array. So I think that's acceptable.Comment #6
catchYep SafeString is a lot more limited than a render array, so no objections to this and it simplifies things as well.
Committed/pushed to 8.0.x, thanks!