vc
This commit is contained in:
parent
4ba3814fd4
commit
073bfa8fcd
5 changed files with 8 additions and 8 deletions
|
@ -27,7 +27,7 @@ CF_HEADERS = {"Authorization": f"Bearer {CF_KEY}", "Content-Type": "application/
|
|||
@auth_desired
|
||||
def post_pid_comment_cid(cid, pid=None, anything=None, v=None):
|
||||
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"/logged_out{request.full_path}")
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
|
|
|
@ -136,7 +136,7 @@ def notifications(v):
|
|||
def front_all(v):
|
||||
|
||||
if not v and request.path == "/" and not request.headers.get("Authorization"):
|
||||
return redirect(f"/logged_out{request.full_path}")
|
||||
return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
|
|
|
@ -98,7 +98,7 @@ def submit_get(v):
|
|||
@auth_desired
|
||||
def post_id(pid, anything=None, v=None):
|
||||
if not v and not request.path.startswith('/logged_out') and not request.headers.get("Authorization"):
|
||||
return redirect(f"/logged_out{request.full_path}")
|
||||
return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ def marsey_list():
|
|||
@app.get("/logged_out/terms")
|
||||
@auth_desired
|
||||
def terms(v):
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"/logged_out{request.full_path}")
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
return render_template("terms.html", v=v)
|
||||
|
@ -40,7 +40,7 @@ def terms(v):
|
|||
@app.get('/logged_out/sidebar')
|
||||
@auth_desired
|
||||
def sidebar(v):
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"/logged_out{request.full_path}")
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
return render_template('sidebar.html', v=v)
|
||||
|
|
|
@ -647,7 +647,7 @@ def visitors(v):
|
|||
def u_username(username, v=None):
|
||||
|
||||
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"/logged_out{request.full_path}")
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
|
@ -754,7 +754,7 @@ def u_username(username, v=None):
|
|||
def u_username_comments(username, v=None):
|
||||
|
||||
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"/logged_out{request.full_path}")
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
|
@ -929,7 +929,7 @@ def remove_follow(username, v):
|
|||
@limiter.exempt
|
||||
@auth_desired
|
||||
def user_profile_uid(v, id):
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"/logged_out{request.full_path}")
|
||||
if not v and not request.path.startswith('/logged_out'): return redirect(f"{SITE_FULL}/logged_out{request.full_path}")
|
||||
if v and request.path.startswith('/logged_out'): v = None
|
||||
|
||||
try: id = int(id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue