Last modified: 2011-01-17 02:30:49 UTC
__NOGALLERY__ occasionally prevents the "The following xxx files are in this category, out of xxx total." from displaying. Instead, it says "The following xxx pages are in the current category." See [[:commons:Category:Deletion requests]] for an example. This only seems to happen when the category has more than 200 members. If the __NOGALLERY__ is removed, the category has no problem showing the total number regardless of size.
It seems to simply confuse the category count method: http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/CategoryPage.php?view=annotate#l466 This has come up before, but I don't see an open bug for it...
Fixing up the category count method, and __NOGALLERY__ for the new category schema in general, happens to fix this bug. (r80433 and r80432)