You are here

public function TfaContext::isModuleSetup in Two-factor Authentication (TFA) 8

Is TFA enabled and configured?

Return value

bool Whether or not the TFA module is configured for use.

Overrides TfaContextInterface::isModuleSetup

File

src/TfaContext.php, line 126

Class

TfaContext
Provide context for the current login attempt.

Namespace

Drupal\tfa

Code

public function isModuleSetup() {
  return intval($this->tfaSettings
    ->get('enabled')) && !empty($this->validationPluginName);
}