diff options
| author | 2013-09-14 21:59:54 +0200 | |
|---|---|---|
| committer | 2013-09-14 21:59:54 +0200 | |
| commit | d9975d86a2d159c0f2442b9ee02f0523b8577af3 (patch) | |
| tree | 75fdc6c51ef5c522593effa0507b36354dcf647b /app/models/Entry.php | |
| parent | 008d6a704748f04687ecf14f587b986d2fe5eacd (diff) | |
Issue #155 : suppression fonctions commentées
Diffstat (limited to 'app/models/Entry.php')
| -rwxr-xr-x | app/models/Entry.php | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/app/models/Entry.php b/app/models/Entry.php index 63e573722..d73ce7245 100755 --- a/app/models/Entry.php +++ b/app/models/Entry.php @@ -461,24 +461,6 @@ class EntryDAO extends Model_pdo { return $unreadRead['unread']; } - /*public function countNotReadByFeed ($id) { //Is this used? - $sql = 'SELECT COUNT(*) AS count FROM ' . $this->prefix . 'entry WHERE is_read = 0 AND id_feed = ?'; - $stm = $this->bd->prepare ($sql); - $stm->execute (array ($id)); - $res = $stm->fetchAll (PDO::FETCH_ASSOC); - - return $res[0]['count']; - }*/ - - /*public function countNotReadByCat ($id) { //Is this used? - $sql = 'SELECT COUNT(*) AS count FROM ' . $this->prefix . 'entry e INNER JOIN ' . $this->prefix . 'feed f ON e.id_feed = f.id WHERE is_read=0 AND category = ?'; - $stm = $this->bd->prepare ($sql); - $stm->execute (array ($id)); - $res = $stm->fetchAll (PDO::FETCH_ASSOC); - - return $res[0]['count']; - }*/ - public function countUnreadReadFavorites () { $sql = 'SELECT is_read, COUNT(*) AS count FROM ' . $this->prefix . 'entry WHERE is_favorite=1 GROUP BY is_read'; $stm = $this->bd->prepare ($sql); @@ -493,10 +475,7 @@ class EntryDAO extends Model_pdo { } return $readUnread; } - /*public function countNotReadFavorites () { //Is this used? //Deprecated: use countUnreadReadFavorites() instead - $unreadRead = $this->countUnreadReadFavorites (); //This makes better use of caching - return $unreadRead['unread']; - }*/ + public function countFavorites () { //Deprecated: use countUnreadReadFavorites() instead $unreadRead = $this->countUnreadReadFavorites (); //This makes better use of caching return $unreadRead['unread'] + $unreadRead['read']; |
