forked from MarseyWorld/MarseyWorld
fix login redir bug
parent
704fb78f20
commit
4eb66e5802
|
@ -106,7 +106,7 @@ def login_post():
|
|||
|
||||
redir = request.values.get("redirect", "").strip().rstrip('?').lower()
|
||||
if redir:
|
||||
if is_site_url(redir) and redir in NO_LOGIN_REDIRECT_URLS:
|
||||
if is_site_url(redir) and redir not in NO_LOGIN_REDIRECT_URLS:
|
||||
return redirect(redir)
|
||||
return redirect('/')
|
||||
|
||||
|
@ -339,7 +339,7 @@ def sign_up_post(v):
|
|||
|
||||
redir = request.values.get("redirect", "").strip().rstrip('?').lower()
|
||||
if redir:
|
||||
if is_site_url(redir) or redir in NO_LOGIN_REDIRECT_URLS:
|
||||
if is_site_url(redir) or redir not in NO_LOGIN_REDIRECT_URLS:
|
||||
return redirect(redir)
|
||||
return redirect('/')
|
||||
|
||||
|
|
Loading…
Reference in New Issue