$out->addHTML( $this->getPageHeader() );
if ( $this->numRows > 0 ) {
$out->addHTML( $this->msg( 'showingresults' )->numParams(
- $this->numRows, $this->offset + 1 )->parseAsBlock() );
+ min( $this->numRows, $this->limit ), # do not show the one extra row, if exist
+ $this->offset + 1 )->parseAsBlock() );
# Disable the "next" link when we reach the end
$paging = $this->getLanguage()->viewPrevNext( $this->getTitle( $par ), $this->offset,
$this->limit, $this->linkParameters(), ( $this->numRows <= $this->limit ) );
$out->addHTML( Xml::closeElement( 'div' ) );
- return $this->numRows;
+ return min( $this->numRows, $this->limit ); # do not return the one extra row, if exist
}
/**