diff --git a/backend/routes/user_routes.py b/backend/routes/user_routes.py index 5d2d6d1..32f9af5 100644 --- a/backend/routes/user_routes.py +++ b/backend/routes/user_routes.py @@ -23,7 +23,6 @@ get_password_hash, verify_password, ) -from settings import SENDGRID_API_KEY, APP_HOST, APP_ENV from utils.email import ( send_password_reset_email_with_sendgrid, send_verification_email_with_sendgrid, @@ -163,9 +162,6 @@ async def reset_password(request: ResetPasswordRequest): async def send_verification_email( request: SendVerificationEmailRequest, background_tasks: BackgroundTasks ): - print( - "APP_ENV", APP_ENV, "APP_HOST", APP_HOST, "SENDGRID_API_KEY", SENDGRID_API_KEY - ) print("Getting user by email") with DatabaseManager() as session: user_manager = UserManager(session) @@ -182,9 +178,10 @@ async def send_verification_email( print("Sending verification email") # Add a background task to send the email - background_tasks.add_task( - send_verification_email_with_sendgrid, user.email, token - ) + # background_tasks.add_task( + # send_verification_email_with_sendgrid, user.email, token + # ) + await send_verification_email_with_sendgrid([user.email], token) return {"message": f"Verification email sent for {user.email}"}