There's no point doing potentially expensive checks (exists() and
getLength()) if the page is simply not in a content namespace.
Change-Id: I86a2b3a36071cf508b8e99ef20bdf3e0e20f3c82
if ( $t->isRedirect() ) {
# Page is a redirect
$colour = 'mw-redirect';
- } elseif ( $threshold > 0 &&
- $t->exists() && $t->getLength() < $threshold &&
- $t->isContentPage() ) {
+ } elseif ( $threshold > 0 && $t->isContentPage() &&
+ $t->exists() && $t->getLength() < $threshold
+ ) {
# Page is a stub
$colour = 'stub';
}