You are here

amazon_ses.install in Amazon SES 2.0.x

Same filename and directory in other branches
  1. 6 amazon_ses.install
  2. 7.2 amazon_ses.install
  3. 7 amazon_ses.install

The install file for the amazon_ses module.

File

amazon_ses.install
View source
<?php

/**
 * @file
 * The install file for the amazon_ses module.
 */

/**
 * Implements hook_requirements().
 */
function amazon_ses_requirements($phase) {
  $requirements = [];
  if ($phase == 'runtime') {
    $config = \Drupal::config('amazon_ses.settings');
    $from_address = $config
      ->get('from_address');
    if (!$from) {
      $requirements['amazon_ses_from_address'] = [
        'title' => t('Amazon SES'),
        'value' => t('From email address not set.'),
        'severity' => REQUIREMENT_ERROR,
      ];
    }
  }
  return $requirements;
}

Functions

Namesort descending Description
amazon_ses_requirements Implements hook_requirements().