fds
This commit is contained in:
parent
f92165e3c9
commit
c528ecc7fa
4 changed files with 12 additions and 12 deletions
|
@ -869,7 +869,8 @@ def toggle_comment_pin(cid, v):
|
|||
if v.admin_level < 1 and v.id != comment.post.author_id:
|
||||
abort(403)
|
||||
|
||||
comment.is_pinned = not comment.is_pinned
|
||||
if comment.is_pinned: comment.is_pinned = None
|
||||
else: comment.is_pinned = v.username
|
||||
|
||||
g.db.add(comment)
|
||||
g.db.flush()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue