https://bugzilla.wikimedia.org/show_bug.cgi?id=8130


[email protected] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
Attachment #5916 is|0                           |1
           obsolete|                            |




--- Comment #8 from [email protected]  2009-04-25 19:19:35 UTC ---
Created an attachment (id=6062)
 --> (https://bugzilla.wikimedia.org/attachment.cgi?id=6062)
Add/implement MWNamespace::getContentNamespaces(), patch for querypage-work
branch

Here's a new patch, written specifically for the querypage-work branch.  The
new function is now MWNamespace::getContentNamespaces().  I went ahead and
added it to every query where I think it should be used.  In the process, I
took a stab at converting SpecialPopularPages over to the new syntax.

In terms of efficiency, using getContentNamespaces() instead of just NS_MAIN
shouldn't have any impact on wikipedia, because the two end up producing
identical SQL.  And as someone who uses a wiki where the content namespaces
have been customized, I'd argue getContentNamespaces() needs to be used in all
possible queries -- because otherwise the corresponding special page ends up
being completely useless.  If performance really is a limiting factors in some
of these queries, it might make more sense to just drop the namespace condition
completely (or at least drop it if the content namespaces have been
customized).

There are a couple of other minor fixes included in the patch that I came
across while doing a quick test-run of the code; I left them in place because
it seemed likely you'd want to make those fixes eventually.  (Specifically,
abstract-ing PageQueryPage, fixing a missing ' in SpecialDeadendpages)


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to