Commit 6dcdd480 authored by Daniele Venzano's avatar Daniele Venzano

Fix pylint errors

parent 605a18e2
......@@ -16,9 +16,10 @@
"""Base authenticator class."""
import logging
import pexpect
from typing import Union
import pexpect
from zoe_api.auth.file import PlainTextAuthenticator
from zoe_api.auth.ldap import LDAPAuthenticator
from zoe_lib.state import SQLManager, User
......@@ -33,7 +34,7 @@ class BaseAuthenticator:
def __init__(self):
self.state = SQLManager(get_conf())
def full_auth(self, username, password) -> Union[None, User]:
def full_auth(self, username, password) -> Union[None, User]: # pylint: disable=too-many-return-statements
"""This method verifies the username and the password against one of the external auth sources."""
user = self.state.user.select(only_one=True, **{"username": username})
if user is None or not user.enabled:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment