mirror of
https://github.com/Doctorado-ML/beflask.git
synced 2025-08-15 07:05:51 +00:00
Merge branch 'main' of github.com:doctorado-ml/beflask
This commit is contained in:
@@ -11,7 +11,7 @@ from flask import (
|
||||
current_app,
|
||||
)
|
||||
from flask_login import login_user, current_user, logout_user, login_required
|
||||
from werkzeug.urls import url_parse
|
||||
from urllib import parse
|
||||
from .forms import LoginForm
|
||||
from .models import User, Benchmark, db
|
||||
|
||||
@@ -95,7 +95,7 @@ def login():
|
||||
db.session.commit()
|
||||
flash("Logged in successfully.")
|
||||
next_page = request.args.get("next")
|
||||
if not next_page or url_parse(next_page).netloc != "":
|
||||
if not next_page or parse(next_page).netloc != "":
|
||||
next_page = url_for(current_app.config["INDEX"])
|
||||
return redirect(next_page)
|
||||
return render_template("login.html", title="Sign In", form=form)
|
||||
|
@@ -7,3 +7,4 @@ flask-socketio
|
||||
flask-wtf
|
||||
simple-websocket
|
||||
email-validator
|
||||
python-dotenv
|
||||
|
Reference in New Issue
Block a user