You are here

public function NodeTabForm::submitTestMail in Simplenews 8.2

Same name and namespace in other branches
  1. 8 src/Form/NodeTabForm.php \Drupal\simplenews\Form\NodeTabForm::submitTestMail()
  2. 3.x src/Form/NodeTabForm.php \Drupal\simplenews\Form\NodeTabForm::submitTestMail()

Submit handler for sending test mails.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: Form state.

File

src/Form/NodeTabForm.php, line 210

Class

NodeTabForm
Configure simplenews subscriptions of a user.

Namespace

Drupal\simplenews\Form

Code

public function submitTestMail(array &$form, FormStateInterface $form_state) {
  $this->mailer
    ->sendTest($form_state
    ->get('node'), $form_state
    ->get('test_addresses'));
}