Forráskód Böngészése

Fix marking as read a label with SQLite (#3711)

Cf. https://github.com/FreshRSS/FreshRSS/pull/3709#issuecomment-885334063
Alexandre Alapetite 4 éve
szülő
commit
247dfa6c1b
1 módosított fájl, 5 hozzáadás és 5 törlés
  1. 5 5
      app/Models/EntryDAOSQLite.php

+ 5 - 5
app/Models/EntryDAOSQLite.php

@@ -253,11 +253,11 @@ DROP TABLE IF EXISTS `tmp`;
 			Minz_Log::debug('Calling markReadTag(0) is deprecated!');
 		}
 
-		$sql = 'UPDATE `_entry` e '
-			 . 'SET e.is_read = ? '
-			 . 'WHERE e.is_read <> ? AND e.id <= ? AND '
-			 . 'e.id IN (SELECT et.id_entry FROM `_entrytag` et '
-			 . ($id == '' ? '' : 'WHERE et.id = ?')
+		$sql = 'UPDATE `_entry` '
+			 . 'SET is_read = ? '
+			 . 'WHERE is_read <> ? AND id <= ? AND '
+			 . 'id IN (SELECT et.id_entry FROM `_entrytag` et '
+			 . ($id == '' ? '' : 'WHERE et.id_tag = ?')
 			 . ')';
 		$values = array($is_read ? 1 : 0, $is_read ? 1 : 0, $idMax);
 		if ($id != '') {