]> git.wh0rd.org Git - tt-rss.git/commitdiff
getLabelCounters: stricter ownership check
authorAndrew Dolgov <noreply@fakecake.org>
Mon, 2 Nov 2015 11:22:37 +0000 (14:22 +0300)
committerAndrew Dolgov <noreply@fakecake.org>
Mon, 2 Nov 2015 11:22:37 +0000 (14:22 +0300)
include/functions.php

index 310081485ec2d097c8984c6987cecaf7f96e5481..e91072271273afa1f04ee4618143296dc40300d7 100644 (file)
                                                        'method' => 'GET',
                                                        'protocol_version'=> 1.1
                                          )));
-                       } 
+                       }
 
                        $old_error = error_get_last();
 
                        FROM ttrss_labels2 LEFT JOIN ttrss_user_labels2 ON
                                (ttrss_labels2.id = label_id)
                                LEFT JOIN ttrss_user_entries AS u1 ON u1.ref_id = article_id
-                               WHERE ttrss_labels2.owner_uid = $owner_uid GROUP BY ttrss_labels2.id,
+                               WHERE ttrss_labels2.owner_uid = $owner_uid AND u1.owner_uid = $owner_uid
+                               GROUP BY ttrss_labels2.id,
                                        ttrss_labels2.caption");
 
                while ($line = db_fetch_assoc($result)) {