X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FPingback.php;h=3b0ab2b6899444df609eb967ea0c4a766b5284bd;hb=0a2b996278e57a8b8c5377cd3a3eaa54f993d4a9;hp=8d7c3b6e4dd2ee1da9e6e39305ba33c697f81af1;hpb=69e70650fc856aaa07c28189df404a3ee79be805;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Pingback.php b/includes/Pingback.php index 8d7c3b6e4d..3b0ab2b689 100644 --- a/includes/Pingback.php +++ b/includes/Pingback.php @@ -22,6 +22,7 @@ use Psr\Log\LoggerInterface; use MediaWiki\Logger\LoggerFactory; +use MediaWiki\MediaWikiServices; /** * Send information about this MediaWiki instance to MediaWiki.org. @@ -195,7 +196,7 @@ class Pingback { 'updatelog', [ 'ul_key' => 'PingBack', 'ul_value' => $id ], __METHOD__, - 'IGNORE' + [ 'IGNORE' ] ); if ( !$dbw->affectedRows() ) { @@ -229,7 +230,7 @@ class Pingback { $json = FormatJson::encode( $data ); $queryString = rawurlencode( str_replace( ' ', '\u0020', $json ) ) . ';'; $url = 'https://www.mediawiki.org/beacon/event?' . $queryString; - return Http::post( $url ) !== false; + return MediaWikiServices::getInstance()->getHttpRequestFactory()->post( $url ) !== null; } /**