forked from rDrama/rDrama
master
parent
9a99c55eba
commit
93fa545ffb
|
@ -994,6 +994,9 @@ def ban_post(post_id, v):
|
||||||
|
|
||||||
cache.delete_memoized(frontlist)
|
cache.delete_memoized(frontlist)
|
||||||
|
|
||||||
|
v.coins += 1
|
||||||
|
g.db.add(v)
|
||||||
|
|
||||||
g.db.commit()
|
g.db.commit()
|
||||||
|
|
||||||
return {"message": "Post removed!"}
|
return {"message": "Post removed!"}
|
||||||
|
@ -1024,6 +1027,9 @@ def unban_post(post_id, v):
|
||||||
|
|
||||||
cache.delete_memoized(frontlist)
|
cache.delete_memoized(frontlist)
|
||||||
|
|
||||||
|
v.coins -= 1
|
||||||
|
g.db.add(v)
|
||||||
|
|
||||||
g.db.commit()
|
g.db.commit()
|
||||||
|
|
||||||
return {"message": "Post approved!"}
|
return {"message": "Post approved!"}
|
||||||
|
|
Loading…
Reference in New Issue