Commit 36d31a8c authored by Abhishek Vishwakarma's avatar Abhishek Vishwakarma Committed by Mohammad AlQanneh
Browse files

Issue #3238233 by visabhishek, mqanneh: User status not checked

parent 14e56ef7
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -52,6 +52,10 @@ class AuthDecorator implements UserAuthInterface {
        $account_search = $this->entityTypeManager->getStorage('user')->loadByProperties(['mail' => $username]);
        if ($account = reset($account_search)) {
          $username = $account->getAccountName();
          if(user_is_blocked($username)) {
            \Drupal::messenger()->addError(t('The user has not been activated yet or is blocked.'));
            return NULL;
          }
        }
      }
      // Check if login by email only option is enabled.