* @ingroup SpecialPage
*/
+use MediaWiki\MediaWikiServices;
+
/**
* A special page that lists autoblocks
*
}
/**
- * Main execution point
- *
- * @param string $par Title fragment
+ * @param string|null $par Title fragment
*/
public function execute( $par ) {
$this->setHeaders();
'ipb_parent_block_id IS NOT NULL'
];
# Is the user allowed to see hidden blocks?
- if ( !$this->getUser()->isAllowed( 'hideuser' ) ) {
+ if ( !MediaWikiServices::getInstance()
+ ->getPermissionManager()
+ ->userHasRight( $this->getUser(), 'hideuser' )
+ ) {
$conds['ipb_deleted'] = 0;
}
protected function showTotal( BlockListPager $pager ) {
$out = $this->getOutput();
$out->addHTML(
- Html::element( 'div', [ 'style' => 'font-weight: bold;' ],
+ Html::rawElement( 'div', [ 'style' => 'font-weight: bold;' ],
$this->msg( 'autoblocklist-total-autoblocks', $pager->getTotalAutoblocks() )->parse() )
. "\n"
);
# Not necessary in a standard installation without such extensions enabled
if ( count( $otherAutoblockLink ) ) {
$out->addHTML(
- Html::element( 'h2', [], $this->msg( 'autoblocklist-localblocks',
+ Html::rawElement( 'h2', [], $this->msg( 'autoblocklist-localblocks',
$pager->getNumRows() )->parse() )
. "\n"
);