You are here

public static function MoAuthUtilities::isCustomerRegistered in Google Authenticator / 2 Factor Authentication - 2FA 8

Same name and namespace in other branches
  1. 8.2 src/MoAuthUtilities.php \Drupal\miniorange_2fa\MoAuthUtilities::isCustomerRegistered()
6 calls to MoAuthUtilities::isCustomerRegistered()
miniorange_2fa_form_alter in ./miniorange_2fa.module
MoAuthLoginSettings::buildForm in src/Form/MoAuthLoginSettings.php
Form constructor.
MoAuthSetupTwoFactor::buildForm in src/Form/MoAuthSetupTwoFactor.php
Form constructor.
MoAuthSetupTwoFactor::mo_auth_create_auth_type in src/Form/MoAuthSetupTwoFactor.php
MoAuthSupport::buildForm in src/Form/MoAuthSupport.php
Form constructor.

... See full list

File

src/MoAuthUtilities.php, line 146
This file is part of miniOrange 2FA module.

Class

MoAuthUtilities

Namespace

Drupal\miniorange_2fa

Code

public static function isCustomerRegistered() {
  if (\Drupal::config('miniorange_2fa.settings')
    ->get('mo_auth_customer_admin_email') == NULL || \Drupal::config('miniorange_2fa.settings')
    ->get('mo_auth_customer_id') == NULL || \Drupal::config('miniorange_2fa.settings')
    ->get('mo_auth_customer_token_key') == NULL || \Drupal::config('miniorange_2fa.settings')
    ->get('mo_auth_customer_api_key') == NULL) {
    return FALSE;
  }
  return TRUE;
}