summaryrefslogtreecommitdiffstats
path: root/core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php
diff options
context:
space:
mode:
Diffstat (limited to 'core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php')
-rw-r--r--core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php b/core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php
index 0ae5084..bce79d6 100644
--- a/core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php
+++ b/core/modules/field_ui/src/Form/FieldStorageConfigEditForm.php
@@ -222,7 +222,7 @@ class FieldStorageConfigEditForm extends EntityForm {
$field_label = $form_state->get('field_config')->label();
try {
$this->entity->save();
- drupal_set_message($this->t('Updated field %label field settings.', ['%label' => $field_label]));
+ $this->messenger()->addStatus($this->t('Updated field %label field settings.', ['%label' => $field_label]));
$request = $this->getRequest();
if (($destinations = $request->query->get('destinations')) && $next_destination = FieldUI::getNextDestination($destinations)) {
$request->query->remove('destinations');
@@ -233,7 +233,7 @@ class FieldStorageConfigEditForm extends EntityForm {
}
}
catch (\Exception $e) {
- drupal_set_message($this->t('Attempt to update field %label failed: %message.', ['%label' => $field_label, '%message' => $e->getMessage()]), 'error');
+ $this->messenger()->addStatus($this->t('Attempt to update field %label failed: %message.', ['%label' => $field_label, '%message' => $e->getMessage()]));
}
}