forked from rDrama/rDrama
make /h/dioceseofrdrama and /h/truth unblockable
parent
f438ad8c4e
commit
046965816e
|
@ -110,8 +110,8 @@ def unexile(v, hole, uid):
|
||||||
@limiter.limit(DEFAULT_RATELIMIT, deduct_when=lambda response: response.status_code < 400, key_func=get_ID)
|
@limiter.limit(DEFAULT_RATELIMIT, deduct_when=lambda response: response.status_code < 400, key_func=get_ID)
|
||||||
@auth_required
|
@auth_required
|
||||||
def block_sub(v, hole):
|
def block_sub(v, hole):
|
||||||
if hole == 'atheism':
|
if hole in {'atheism', 'dioceseofrdrama', 'truth'}:
|
||||||
abort(403, "/h/atheism is unblockable!")
|
abort(403, f"/h/{hole} is unblockable!")
|
||||||
|
|
||||||
hole = get_hole(hole).name
|
hole = get_hole(hole).name
|
||||||
existing = g.db.query(HoleBlock).filter_by(user_id=v.id, hole=hole).one_or_none()
|
existing = g.db.query(HoleBlock).filter_by(user_id=v.id, hole=hole).one_or_none()
|
||||||
|
|
Loading…
Reference in New Issue