You are here

class MigrateMailIgnore in Migrate 7.2

@file Null-op mail class, to keep migration from spamming innocent users.

Hierarchy

Expanded class hierarchy of MigrateMailIgnore

2 string references to 'MigrateMailIgnore'
MigrateNodeUnitTest::testNodeImport in tests/plugins/destinations/node.test
MigrationBase::disableMailSystem in includes/base.inc
Disables mail system to prevent emails from being sent during migrations.

File

./migrate.mail.inc, line 8
Null-op mail class, to keep migration from spamming innocent users.

View source
class MigrateMailIgnore extends DefaultMailSystem {

  /**
   * On an email request, do nothing and say we did.
   *
   * @see http://php.net/manual/en/function.mail.php
   * @see drupal_mail()
   *
   * @param $message
   *   A message array, as described in hook_mail_alter().
   *
   * @return
   *   TRUE if the mail was successfully accepted, otherwise FALSE.
   */
  public function mail(array $message) {
    return TRUE;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
DefaultMailSystem::format public function Concatenate and wrap the e-mail body for plain-text mails. Overrides MailSystemInterface::format
DefaultMailSystem::_isShellSafe protected static function Disallows potentially unsafe shell characters.
MigrateMailIgnore::mail public function On an email request, do nothing and say we did. Overrides DefaultMailSystem::mail