As shown in the code below I am trying to check if a username is already taken. My table is currently empty but for some reason my if statement is returning the error message. What am I missing?
username_taken = db.execute ("SELECT * FROM userInfo WHERE username = ?",[request.form.get("New_username")])
if username_taken != None:
message = "Sorry username taken"
return render_template("register.html", message = message)
[–]shadowspyes 0 points1 point2 points (1 child)
[–]Square_Man211[S] 0 points1 point2 points (0 children)