X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiQueryImages.php;h=ae6f5bf564aa1ba3278fd97ddbd43062eba794d3;hb=20f0da437eeed7e8ca28be911f53535be82889a1;hp=e04d8c888f1fdc6251130bdb8496aff772c9021c;hpb=6e9b4f0e9ce4ccd6089c18b205065ef7fa077484;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiQueryImages.php b/includes/api/ApiQueryImages.php index e04d8c888f..ae6f5bf564 100644 --- a/includes/api/ApiQueryImages.php +++ b/includes/api/ApiQueryImages.php @@ -90,7 +90,7 @@ class ApiQueryImages extends ApiQueryGeneratorBase { foreach ( $params['images'] as $img ) { $title = Title::newFromText( $img ); if ( !$title || $title->getNamespace() != NS_FILE ) { - $this->setWarning( "\"$img\" is not a file" ); + $this->addWarning( [ 'apiwarn-notfile', wfEscapeWikiText( $img ) ] ); } else { $images[] = $title->getDBkey(); }