diff --git a/core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php b/core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php index e0f6d0896be66f0778e54d456abc21d04ade04e0..dab1c6d14326847e2e81d7bb7a9e9b20dcc75bea 100644 --- a/core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php +++ b/core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php @@ -143,7 +143,7 @@ public function execute($entity = NULL) { $message = $this->mailManager->mail('system', 'action_send_email', $recipient, $langcode, $params); // Error logging is handled by \Drupal\Core\Mail\MailManager::mail(). if ($message['result']) { - $this->logger->notice('Sent email to %recipient', ['%recipient' => $recipient]); + $this->logger->info('Sent email to %recipient', ['%recipient' => $recipient]); } } diff --git a/core/modules/comment/src/CommentForm.php b/core/modules/comment/src/CommentForm.php index ba4047d45fb741107c926c718a9769f2a9c6228e..7bd37d3b118c418c8febcdff8cd6564bd822f85c 100644 --- a/core/modules/comment/src/CommentForm.php +++ b/core/modules/comment/src/CommentForm.php @@ -381,7 +381,7 @@ public function save(array $form, FormStateInterface $form_state) { $form_state->setValue('cid', $comment->id()); // Add a log entry. - $logger->notice('Comment posted: %subject.', [ + $logger->info('Comment posted: %subject.', [ '%subject' => $comment->getSubject(), 'link' => Link::fromTextAndUrl(t('View'), $comment->toUrl()->setOption('fragment', 'comment-' . $comment->id()))->toString(), ]); diff --git a/core/modules/comment/src/Form/DeleteForm.php b/core/modules/comment/src/Form/DeleteForm.php index 84ff1f999d503f7112c43d7b2c2caeaae1c8cb13..5be6d10aa1652fa4877058cd3a3a2bec986867f6 100644 --- a/core/modules/comment/src/Form/DeleteForm.php +++ b/core/modules/comment/src/Form/DeleteForm.php @@ -44,7 +44,7 @@ protected function getDeletionMessage() { * {@inheritdoc} */ public function logDeletionMessage() { - $this->logger('comment')->notice('Deleted comment @cid and its replies.', ['@cid' => $this->entity->id()]); + $this->logger('comment')->info('Deleted comment @cid and its replies.', ['@cid' => $this->entity->id()]); } } diff --git a/core/modules/contact/src/MailHandler.php b/core/modules/contact/src/MailHandler.php index eb1860d82d103b512c729ad000aa2030d177106b..9e8f323e98c71f72589b65ad807543089a600955 100644 --- a/core/modules/contact/src/MailHandler.php +++ b/core/modules/contact/src/MailHandler.php @@ -133,14 +133,14 @@ public function sendMailMessages(MessageInterface $message, AccountInterface $se } if (!$message->isPersonal()) { - $this->logger->notice('%sender-name (@sender-from) sent an email regarding %contact_form.', [ + $this->logger->info('%sender-name (@sender-from) sent an email regarding %contact_form.', [ '%sender-name' => $sender_cloned->getAccountName(), '@sender-from' => $sender_cloned->getEmail() ?? '', '%contact_form' => $contact_form->label(), ]); } else { - $this->logger->notice('%sender-name (@sender-from) sent %recipient-name an email.', [ + $this->logger->info('%sender-name (@sender-from) sent %recipient-name an email.', [ '%sender-name' => $sender_cloned->getAccountName(), '@sender-from' => $sender_cloned->getEmail(), '%recipient-name' => $message->getPersonalRecipient()->getAccountName(), diff --git a/core/modules/contact/tests/src/Unit/MailHandlerTest.php b/core/modules/contact/tests/src/Unit/MailHandlerTest.php index 1b3d34784bed8d19853078c73ba481a4eee99d7d..50b32628d8b2f3df1371f1fcf76e7857d55a4335 100644 --- a/core/modules/contact/tests/src/Unit/MailHandlerTest.php +++ b/core/modules/contact/tests/src/Unit/MailHandlerTest.php @@ -135,7 +135,7 @@ public function testInvalidRecipient() { */ public function testSendMailMessages(MessageInterface $message, AccountInterface $sender, $results) { $this->logger->expects($this->once()) - ->method('notice'); + ->method('info'); $this->mailManager->expects($this->any()) ->method('mail') ->willReturnCallback( diff --git a/core/modules/search/src/Controller/SearchController.php b/core/modules/search/src/Controller/SearchController.php index b10c3f9218035c7199eefec1a39bcc82d36ec431..c44110f84db28d8315a9cfe9a70eff2442efaf6a 100644 --- a/core/modules/search/src/Controller/SearchController.php +++ b/core/modules/search/src/Controller/SearchController.php @@ -95,7 +95,7 @@ public function view(Request $request, SearchPageInterface $entity) { if ($plugin->isSearchExecutable()) { // Log the search. if ($this->config('search.settings')->get('logging')) { - $this->logger->notice('Searched %type for %keys.', ['%keys' => $keys, '%type' => $entity->label()]); + $this->logger->info('Searched %type for %keys.', ['%keys' => $keys, '%type' => $entity->label()]); } // Collect the search results. diff --git a/core/modules/taxonomy/src/TermForm.php b/core/modules/taxonomy/src/TermForm.php index 061262f8e5ce1478007b09a3c2f546ed860dbfee..3bf3f204130b470b8512a09bbe06ff2a8009aaf8 100644 --- a/core/modules/taxonomy/src/TermForm.php +++ b/core/modules/taxonomy/src/TermForm.php @@ -201,12 +201,12 @@ public function save(array $form, FormStateInterface $form_state) { switch ($result) { case SAVED_NEW: $this->messenger()->addStatus($this->t('Created new term %term.', ['%term' => $view_link])); - $this->logger('taxonomy')->notice('Created new term %term.', ['%term' => $term->getName(), 'link' => $edit_link]); + $this->logger('taxonomy')->info('Created new term %term.', ['%term' => $term->getName(), 'link' => $edit_link]); break; case SAVED_UPDATED: $this->messenger()->addStatus($this->t('Updated term %term.', ['%term' => $view_link])); - $this->logger('taxonomy')->notice('Updated term %term.', ['%term' => $term->getName(), 'link' => $edit_link]); + $this->logger('taxonomy')->info('Updated term %term.', ['%term' => $term->getName(), 'link' => $edit_link]); $form_state->setRedirect('entity.taxonomy_term.canonical', ['taxonomy_term' => $term->id()]); break; }