X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=web%2Fcore%2Fmodules%2Fsystem%2Ftests%2Fmodules%2Fsession_test%2Fsrc%2FForm%2FSessionTestForm.php;fp=web%2Fcore%2Fmodules%2Fsystem%2Ftests%2Fmodules%2Fsession_test%2Fsrc%2FForm%2FSessionTestForm.php;h=b324c9729846bd47a1c73b606876a52c9c186237;hp=c09237ac6bdbc4e4d5db592fa67c998851563236;hb=0bf8d09d2542548982e81a441b1f16e75873a04f;hpb=74df008bdbb3a11eeea356744f39b802369bda3c diff --git a/web/core/modules/system/tests/modules/session_test/src/Form/SessionTestForm.php b/web/core/modules/system/tests/modules/session_test/src/Form/SessionTestForm.php index c09237ac6..b324c9729 100644 --- a/web/core/modules/system/tests/modules/session_test/src/Form/SessionTestForm.php +++ b/web/core/modules/system/tests/modules/session_test/src/Form/SessionTestForm.php @@ -2,7 +2,7 @@ namespace Drupal\session_test\Form; -use Drupal\Component\Utility\SafeMarkup; +use Drupal\Component\Render\FormattableMarkup; use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; @@ -43,7 +43,7 @@ class SessionTestForm extends FormBase { * {@inheritdoc} */ public function submitForm(array &$form, FormStateInterface $form_state) { - drupal_set_message(SafeMarkup::format('Ok: @input', ['@input' => $form_state->getValue('input')])); + $this->messenger()->addStatus(new FormattableMarkup('Ok: @input', ['@input' => $form_state->getValue('input')])); } }