fdsfsd
This commit is contained in:
parent
5e6c071576
commit
18169b1c6d
1 changed files with 4 additions and 0 deletions
|
@ -61,6 +61,8 @@ def admin_vote_info_get(v):
|
|||
@validate_formkey
|
||||
def api_vote_post(post_id, new, v):
|
||||
|
||||
if v.is_banned and not v.unban_utc: return {"error": "forbidden."}, 403
|
||||
|
||||
if new not in ["-1", "0", "1"]: abort(400)
|
||||
|
||||
if request.headers.get("Authorization"): abort(403)
|
||||
|
@ -118,6 +120,8 @@ def api_vote_post(post_id, new, v):
|
|||
@validate_formkey
|
||||
def api_vote_comment(comment_id, new, v):
|
||||
|
||||
if v.is_banned and not v.unban_utc: return {"error": "forbidden."}, 403
|
||||
|
||||
if new not in ["-1", "0", "1"]: abort(400)
|
||||
|
||||
if request.headers.get("Authorization"): abort(403)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue