From: River Tarnell Date: Thu, 10 May 2007 15:36:29 +0000 (+0000) Subject: when $threshold is 0, page_len and page_is_redirect are not present in $s; causes... X-Git-Tag: 1.31.0-rc.0~52978 X-Git-Url: https://git.cyclocoop.org/%7B%24admin_url%7Dmembres/modifier.php?a=commitdiff_plain;h=f23877bb9c9871efcf2a487441bc7045b44e1e0b;p=lhc%2Fweb%2Fwiklou.git when $threshold is 0, page_len and page_is_redirect are not present in $s; causes PHP errors and spurious stub display --- diff --git a/includes/Parser.php b/includes/Parser.php index 966b82c3f2..2d053e7a29 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -4074,9 +4074,10 @@ class Parser $linkCache->addGoodLinkObj( $s->page_id, $title ); $this->mOutput->addLink( $title, $s->page_id ); - $colours[$pdbk] = ( $s->page_len >= $threshold || # always true if $threshold <= 0 - $s->page_is_redirect || - !Namespace::isContent( $s->page_namespace ) + $colours[$pdbk] = ( $threshold == 0 || ( + $s->page_len >= $threshold || # always true if $threshold <= 0 + $s->page_is_redirect || + !Namespace::isContent( $s->page_namespace ) ) ? 1 : 2 ); } }