fix: magic code when smtp is not configured (#4767)

This commit is contained in:
Nikhil 2024-06-12 18:45:16 +05:30 committed by GitHub
parent 060fe8ebcc
commit 3165c3b1d3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -48,7 +48,7 @@ class MagicCodeProvider(CredentialAdapter):
raise AuthenticationException(
error_code=AUTHENTICATION_ERROR_CODES["SMTP_NOT_CONFIGURED"],
error_message="SMTP_NOT_CONFIGURED",
payload={"email": str(self.key)},
payload={"email": str(key)},
)
if ENABLE_MAGIC_LINK_LOGIN == "0":
@ -57,7 +57,7 @@ class MagicCodeProvider(CredentialAdapter):
"MAGIC_LINK_LOGIN_DISABLED"
],
error_message="MAGIC_LINK_LOGIN_DISABLED",
payload={"email": str(self.key)},
payload={"email": str(key)},
)
super().__init__(