Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / config / tests / config_test / src / ConfigTestForm.php
index fbc0f9661d5f84875d4c9e1b6a4983517a077435..86e021e38c2cd11ba79c93bb3dcf3841c8c50173 100644 (file)
@@ -138,10 +138,10 @@ class ConfigTestForm extends EntityForm {
     $status = $entity->save();
 
     if ($status === SAVED_UPDATED) {
-      drupal_set_message(format_string('%label configuration has been updated.', ['%label' => $entity->label()]));
+      $this->messenger()->addStatus(format_string('%label configuration has been updated.', ['%label' => $entity->label()]));
     }
     else {
-      drupal_set_message(format_string('%label configuration has been created.', ['%label' => $entity->label()]));
+      $this->messenger()->addStatus(format_string('%label configuration has been created.', ['%label' => $entity->label()]));
     }
 
     $form_state->setRedirectUrl($this->entity->urlInfo('collection'));