Pass next URL to OAuth

This commit is contained in:
Edward Betts 2019-09-27 20:23:01 +01:00
parent 51c245d637
commit 37af9ad1c0
2 changed files with 7 additions and 1 deletions

6
app.py
View file

@ -115,6 +115,12 @@ def set_url_args(**new_args):
args = {k: v for k, v in args.items() if v is not None}
return url_for(request.endpoint, **args)
@app.template_global()
def current_url():
args = request.view_args.copy()
args.update(request.args)
return url_for(request.endpoint, **args)
@app.before_request
def init_profile():
g.profiling = []