Comment: | Refresh category table counts sometimes for small categories
When someone views a category page, if the number of retrieved pages is the whole category (no from= or until=, 200 or less retrieved), and that number doesn't match the number in the category table, we already detect that this is wrong and ignore the bogus category table number. Now the software also refreshes the bogus category counts in the database in this case, which should be pretty much instantaneous since it has less than 200 entries.
This adds no overhead for categories that have correct counts, and fixes the most visible case when category counts are wrong: small categories, when you can easily count the pages. |