Closed ServiusHack closed 8 years ago
Migration code is here: https://github.com/owncloud/news/blob/master/upgrade/upgrade.php#L50
Search indices were introduced in 6.1.2 so that code should have been run. Will check later ;)
Can you set your database version to 6.1.2. and check if the db migration fixes it?
UPDATE oc_appconfig SET configvalue = '6.1.2' WHERE appid = 'news' and configkey = 'installed_version';
The db migration fixed it. Running SELECT count(*) FROM oc_news_items WHERE fingerprint IS NULL
returns 0 and marking items as read persists upon page reload. Thank you for your help and this great app!
I recently noticed that I can't mark old items of news feeds as read. The UI updates correctly but after reloading the page the item is shown as unread. The following describes what I found out and believe to be the root cause.
The request is correctly processed and this query is sent to the database:
The following parameters are used:
Here you can see the problem. The parameter for
WHERE fingerprint = ?
isnull
thus the above query will never match any row (= null
is always false).Fingerprints were introduced with fae882f834409e18174e05d19deea39a3bf01e7b. Commit 65d28653ae1a1d2a7680ccfa694dbb7e2d4d750f started using them to mark items as read. Still, even in the recent version I can't find migration code which adds fingerprints for old items. They will always be null and can never be marked as read.
System Information