You are here

public function PostmarkHandler::__construct in Postmark 8

Constructs a new PostmarkHandler object.

Parameters

\Drupal\Core\Config\ConfigFactoryInterface $configFactory: The config factory.

\Psr\Log\LoggerInterface $logger: A logger instance.

File

src/PostmarkHandler.php, line 44

Class

PostmarkHandler
Mail handler to send out an email message array to the Postmark API.

Namespace

Drupal\postmark

Code

public function __construct(ConfigFactoryInterface $configFactory, LoggerInterface $logger) {
  $this->config = $configFactory
    ->get('postmark.settings');
  $this->logger = $logger;
  $this->postmarkClient = new PostmarkClient($this->config
    ->get('postmark_api_key'));
}