]> git.wh0rd.org Git - tt-rss.git/commitdiff
mail plugin: only mail unique articles
authorAndrew Dolgov <noreply@fakecake.org>
Wed, 2 Jul 2014 05:53:58 +0000 (09:53 +0400)
committerAndrew Dolgov <noreply@fakecake.org>
Wed, 2 Jul 2014 05:53:58 +0000 (09:53 +0400)
plugins/mail/init.php

index 5b61c2355517c6ab4e0fb9d8d3dae02fba0673f2..5fcdf32af9a2f662bd10267be3fb64395d369183 100644 (file)
@@ -56,7 +56,7 @@ class Mail extends Plugin {
                $tpl->setVariable('USER_EMAIL', $user_email, true);
                $tpl->setVariable('TTRSS_HOST', $_SERVER["HTTP_HOST"], true);
 
-               $result = db_query("SELECT link, content, title, note 
+               $result = db_query("SELECT DISTINCT link, content, title, note
                        FROM ttrss_user_entries, ttrss_entries WHERE id = ref_id AND
                        id IN ($param) AND owner_uid = " . $_SESSION["uid"]);