Skip to content

Commit

Permalink
added env import to utils.py
Browse files Browse the repository at this point in the history
  • Loading branch information
brwali committed Nov 17, 2023
1 parent 225e1ae commit 64da6df
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/recommenderapp/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import smtplib
import os
import hashlib
from dotenv import load_dotenv
from smtplib import SMTPException
from email.mime.text import MIMEText
from email.mime.multipart import MIMEMultipart
Expand Down Expand Up @@ -179,6 +180,7 @@ def send_email_to_user(recipient_email, categorized_data):
def createAccount(db, email, username, password):
executor = db.cursor()
#salt our password
load_dotenv()
newPass = (password + os.getenv("SALT") + username).encode()
#now hash it
h = hashlib.sha256()
Expand Down

0 comments on commit 64da6df

Please sign in to comment.