Same name and namespace in other branches
  1. 8.9.x core/core.api.php \hook_mail_backend_info_alter()
  2. 9 core/core.api.php \hook_mail_backend_info_alter()

Alter the list of mail backend plugin definitions.

Parameters

array $info: The mail backend plugin definitions to be altered.

See also

\Drupal\Core\Annotation\Mail

\Drupal\Core\Mail\MailManager

Related topics

1 invocation of hook_mail_backend_info_alter()
MailManager::__construct in core/lib/Drupal/Core/Mail/MailManager.php
Constructs the MailManager object.

File

core/core.api.php, line 2146
Documentation landing page and topics, plus core library hooks.

Code

function hook_mail_backend_info_alter(&$info) {
  unset($info['test_mail_collector']);
}