aboutsummaryrefslogtreecommitdiff
path: root/app/Models/EntryDAO.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/Models/EntryDAO.php')
-rw-r--r--app/Models/EntryDAO.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Models/EntryDAO.php b/app/Models/EntryDAO.php
index 7b7f5f53e..2e4f52d0b 100644
--- a/app/Models/EntryDAO.php
+++ b/app/Models/EntryDAO.php
@@ -546,7 +546,7 @@ SQL;
* @param integer $idMax max article ID
* @return integer affected rows
*/
- public function markReadTag($id = '', $idMax = 0, $filters = null, $state = 0, $is_read = true) {
+ public function markReadTag($id = 0, $idMax = 0, $filters = null, $state = 0, $is_read = true) {
FreshRSS_UserDAO::touch();
if ($idMax == 0) {
$idMax = time() . '000000';
@@ -556,10 +556,10 @@ SQL;
$sql = 'UPDATE `_entry` e INNER JOIN `_entrytag` et ON et.id_entry = e.id '
. 'SET e.is_read = ? '
. 'WHERE '
- . ($id == '' ? '' : 'et.id_tag = ? AND ')
+ . ($id == 0 ? '' : 'et.id_tag = ? AND ')
. 'e.is_read <> ? AND e.id <= ?';
$values = array($is_read ? 1 : 0);
- if ($id != '') {
+ if ($id != 0) {
$values[] = $id;
}
$values[] = $is_read ? 1 : 0;