=> 326e63dab1e65bcf0e2427d9a93b017999c5e11e
[1mdiff --git a/model.py b/model.py[m [1mindex 022eb29..95e9b44 100644[m [1m--- a/model.py[m [1m+++ b/model.py[m [36m@@ -1074,10 +1074,11 @@[m [mclass Database:[m FOLLOW_POST, parent_post.id)[m [m if parent_post.user != user.id:[m [32m+[m[32m # Notify post author of a new comment.[m cur.execute("INSERT IGNORE INTO notifs (type, dst, src, post) VALUES (?, ?, ?, ?)",[m (Notification.COMMENT, parent_post.user, user.id, parent_post.id))[m [m [31m- # Delete redundant lower-priority notifications.[m [32m+[m[32m # Delete redundant lower-priority notification going to post author.[m cur.execute("DELETE FROM notifs WHERE (type & ?) AND is_hidden=FALSE AND "[m "dst=? AND src=? AND post=?",[m (Notification.COMMENT_IN_FOLLOWED_SUBSPACE |[m [36m@@ -1573,6 +1574,21 @@[m [mclass Database:[m """)[m self.commit()[m [m [32m+[m[32m # Delete redundant notifications.[m [32m+[m[32m if follow_type == FOLLOW_POST:[m [32m+[m[32m cur.execute(f"""[m [32m+[m[32m DELETE FROM notifs[m [32m+[m[32m WHERE (type & ?) AND src=? AND post=? AND is_hidden=FALSE AND dst IN ([m [32m+[m[32m SELECT user[m [32m+[m[32m FROM follow[m [32m+[m[32m WHERE type={FOLLOW_POST} AND target={target_id}[m [32m+[m[32m )""",[m [32m+[m[32m (Notification.COMMENT_ON_COMMENTED |[m [32m+[m[32m Notification.COMMENT_BY_FOLLOWED_USER,[m [32m+[m[32m actor.id,[m [32m+[m[32m target_id))[m [32m+[m[32m self.commit()[m [32m+[m def notify_new_poll(self, post: Post):[m cur = self.conn.cursor()[m cur.execute(f"""[m
text/gemini; charset=utf-8
This content has been proxied by September (ba2dc).