forked from rDrama/rDrama
fsdfsd]
parent
88c77fad30
commit
bdac78658d
|
@ -362,7 +362,7 @@ def buy(v, award):
|
||||||
@auth_required
|
@auth_required
|
||||||
def award_post(pid, v):
|
def award_post(pid, v):
|
||||||
|
|
||||||
if v.is_suspended and v.unban_utc == 0: return {"error": "forbidden."}, 403
|
if v.is_banned and not v.unban_utc: return {"error": "forbidden."}, 403
|
||||||
|
|
||||||
kind = request.values.get("kind", "").strip()
|
kind = request.values.get("kind", "").strip()
|
||||||
|
|
||||||
|
|
|
@ -904,10 +904,12 @@ def settings_content_get(v):
|
||||||
|
|
||||||
@app.post("/settings/name_change")
|
@app.post("/settings/name_change")
|
||||||
@limiter.limit("1/second")
|
@limiter.limit("1/second")
|
||||||
@is_not_banned
|
@auth_required
|
||||||
@validate_formkey
|
@validate_formkey
|
||||||
def settings_name_change(v):
|
def settings_name_change(v):
|
||||||
|
|
||||||
|
if v.is_banned and not v.unban_utc: return {"error": "forbidden."}, 403
|
||||||
|
|
||||||
new_name=request.values.get("name").strip()
|
new_name=request.values.get("name").strip()
|
||||||
|
|
||||||
if new_name==v.username:
|
if new_name==v.username:
|
||||||
|
|
Loading…
Reference in New Issue