forked from rDrama/rDrama
hide modmail messages from muted users in the main notifications tab (they still appear in the modmail tab)
parent
42e40c1691
commit
9b85fd5dd5
|
@ -299,6 +299,8 @@ def notifications(v):
|
||||||
if x.replies2 == None:
|
if x.replies2 == None:
|
||||||
x.replies2 = g.db.query(Comment).filter_by(parent_comment_id=x.id).filter(or_(Comment.author_id == v.id, Comment.id.in_(cids))).order_by(Comment.id.desc()).all()
|
x.replies2 = g.db.query(Comment).filter_by(parent_comment_id=x.id).filter(or_(Comment.author_id == v.id, Comment.id.in_(cids))).order_by(Comment.id.desc()).all()
|
||||||
else:
|
else:
|
||||||
|
if c.sentto == 2 and c.author.is_muted:
|
||||||
|
continue
|
||||||
while c.parent_comment:
|
while c.parent_comment:
|
||||||
c = c.parent_comment
|
c = c.parent_comment
|
||||||
c.replies2 = g.db.query(Comment).filter_by(parent_comment_id=c.id).order_by(Comment.id).all()
|
c.replies2 = g.db.query(Comment).filter_by(parent_comment_id=c.id).order_by(Comment.id).all()
|
||||||
|
|
Loading…
Reference in New Issue