Pass the target as a string to the reason Message for autoblocks

Bug: T227007
Change-Id: Id56c7f41d96e378ff43d152ff7325de49be66df9
This commit is contained in:
Thalia 2019-10-22 16:51:10 +01:00
parent 533346b24f
commit a652bb330a

View file

@ -847,7 +847,7 @@ class DatabaseBlock extends AbstractBlock {
$autoblock->setTarget( $autoblockIP );
$autoblock->setBlocker( $this->getBlocker() );
$autoblock->setReason(
wfMessage( 'autoblocker', $this->getTarget(), $this->getReasonComment()->text )
wfMessage( 'autoblocker', (string)$this->getTarget(), $this->getReasonComment()->text )
);
$timestamp = wfTimestampNow();
$autoblock->setTimestamp( $timestamp );