Newly registered user logged in directly

This commit is contained in:
crunk 2022-01-09 13:10:20 +01:00
parent d7936dc3e0
commit 1a50898d21

View File

@ -100,6 +100,7 @@ def register():
db.session.add(newuser) db.session.add(newuser)
db.session.commit() db.session.commit()
flash("Account Succesfully created", "success") flash("Account Succesfully created", "success")
login_user(newuser)
return redirect(url_for("index")) return redirect(url_for("index"))
except InvalidRequestError: except InvalidRequestError: