Autoblocks triggered latest block log entry being displayed, which was
naturally the wrong one, since autoblocks are not put into a block log.
Change-Id: Ic08880c18a778d5294bb934c764a70dbd7800b70
$links = $this->getLanguage()->pipeList( $tools );
// Show a note if the user is blocked and display the last block log entry.
- if ( $userObj->isBlocked() ) {
+ // Do not expose the autoblocks, since that may lead to a leak of accounts' IPs,
+ // and also this will display a totally irrelevant log entry as a current block.
+ if ( $userObj->isBlocked() && $userObj->getBlock()->getType() != Block::TYPE_AUTO ) {
$out = $this->getOutput(); // showLogExtract() wants first parameter by reference
LogEventsList::showLogExtract(
$out,