upgrade flask to 2.3.2 and replace g.user with current_user

This commit is contained in:
pycook
2023-08-06 19:12:44 +08:00
committed by pycook
parent 16d6b40e8d
commit 9bbbcbe6dc
23 changed files with 130 additions and 149 deletions

View File

@@ -1,14 +1,7 @@
# -*- coding: utf-8 -*-
"""Create an application instance."""
from flask import g
from flask_login import current_user
from api.app import create_app
app = create_app()
@app.before_request
def before_request():
g.user = current_user