Page MenuHomePhabricator

CategoryViewer has $from defined as String but is used later as array
Closed, ResolvedPublic

Description

Author: eloy

Description:
definition of constructor from CategoryViewer.php:

function __construct( $title, IContextSource $context, $from = '', $until = '', $query = array() ) {
[...]
}

but later in function doCategoryQuery:
[...]

			if ( $this->from[$type] !== null ) {

[...]
and in private function getSectionPagingLinks( $type ):
[...]

		} elseif ( $this->nextPage[$type] !== null || $this->from[$type] !== null ) {

[...]

Parameter "from" should be probably defined in constructor as empty array() and/or later in code added to some is_array() condition.


Version: 1.20.x
Severity: minor

Details

Reference
bz37195

Event Timeline

bzimport raised the priority of this task from to Low.Nov 22 2014, 12:27 AM
bzimport set Reference to bz37195.
bzimport added a subscriber: Unknown Object (MLST).

Thanks for catching that.

gerrit change 39524