X-Git-Url: http://aleph1.co.uk/gitweb/?a=blobdiff_plain;f=web%2Fcore%2Fmodules%2Fblock_content%2Fsrc%2FBlockContentTypeForm.php;h=711cda678b7e1452491ca65328b7b079279ab525;hb=5b8bb166bfa98770daef9de5c127fc2e6ef02340;hp=4e140b19322efceccfdde2417094a344958bdd1a;hpb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;p=yaffs-website diff --git a/web/core/modules/block_content/src/BlockContentTypeForm.php b/web/core/modules/block_content/src/BlockContentTypeForm.php index 4e140b193..711cda678 100644 --- a/web/core/modules/block_content/src/BlockContentTypeForm.php +++ b/web/core/modules/block_content/src/BlockContentTypeForm.php @@ -8,7 +8,9 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\language\Entity\ContentLanguageSettings; /** - * Base form for category edit forms. + * The block content type entity form. + * + * @internal */ class BlockContentTypeForm extends BundleEntityFormBase { @@ -98,12 +100,12 @@ class BlockContentTypeForm extends BundleEntityFormBase { $edit_link = $this->entity->link($this->t('Edit')); $logger = $this->logger('block_content'); if ($status == SAVED_UPDATED) { - drupal_set_message(t('Custom block type %label has been updated.', ['%label' => $block_type->label()])); + $this->messenger()->addStatus(t('Custom block type %label has been updated.', ['%label' => $block_type->label()])); $logger->notice('Custom block type %label has been updated.', ['%label' => $block_type->label(), 'link' => $edit_link]); } else { block_content_add_body_field($block_type->id()); - drupal_set_message(t('Custom block type %label has been added.', ['%label' => $block_type->label()])); + $this->messenger()->addStatus(t('Custom block type %label has been added.', ['%label' => $block_type->label()])); $logger->notice('Custom block type %label has been added.', ['%label' => $block_type->label(), 'link' => $edit_link]); }