You are here

function samlauth_form_user_admin_settings_alter in SAML Authentication 4.x

Same name and namespace in other branches
  1. 8.3 samlauth.module \samlauth_form_user_admin_settings_alter()

Implements hook_form_FORM_ID_alter() for the Core account settings form.

File

./samlauth.module, line 153
Allows users to authenticate against an external SAML identity provider.

Code

function samlauth_form_user_admin_settings_alter(&$form, FormStateInterface $form_state) {
  if (\Drupal::config(SamlController::CONFIG_OBJECT_NAME)
    ->get('create_users') && !isset($form['registration_cancellation']['#description'])) {
    $form['registration_cancellation']['#description'] = t('Registration settings do not apply to accounts created by logging in through an external authentication provider.');
  }
}