jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/360173 )
Change subject: build: Updating mediawiki/mediawiki-codesniffer to 0.10.0
......................................................................
build: Updating mediawiki/mediawiki-codesniffer to 0.10.0
The following sniffs are failing and were disabled:
* MediaWiki.Commenting.FunctionComment.ExtraParamComment
* MediaWiki.Commenting.FunctionComment.MissingParamComment
* MediaWiki.Commenting.FunctionComment.MissingParamName
* MediaWiki.Commenting.FunctionComment.MissingParamTag
* MediaWiki.Commenting.FunctionComment.MissingReturn
* MediaWiki.Commenting.FunctionComment.ParamNameNoMatch
* MediaWiki.FunctionComment.Missing.Protected
* MediaWiki.FunctionComment.Missing.Public
* MediaWiki.NamingConventions.LowerCamelFunctionsName.FunctionName
* MediaWiki.Usage.SuperGlobalsUsage.SuperGlobals
* MediaWiki.WhiteSpace.SpaceBeforeSingleLineComment.NewLineComment
Change-Id: Id98f147b80e9fa4a78eedf2b194c73f0dc10d11f
---
M composer.json
M includes/Forms/MetadataMappingForm.php
M includes/Handlers/UploadHandler.php
M includes/Handlers/Xml/XmlMappingHandler.php
M includes/Helpers/WikiChecks.php
M includes/Jobs/UploadMediafileJob.php
M includes/Utils.php
M maintenance/cleanupGWTFileBackend.php
M phpcs.xml
9 files changed, 18 insertions(+), 11 deletions(-)
Approvals:
Umherirrender: Looks good to me, approved
jenkins-bot: Verified
diff --git a/composer.json b/composer.json
index e3e4a41..579fe1f 100644
--- a/composer.json
+++ b/composer.json
@@ -1,7 +1,7 @@
{
"require-dev": {
"jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.7.2",
+ "mediawiki/mediawiki-codesniffer": "0.10.0",
"jakub-onderka/php-console-highlighter": "0.3.2"
},
"scripts": {
diff --git a/includes/Forms/MetadataMappingForm.php
b/includes/Forms/MetadataMappingForm.php
index c522b4c..bb2a4c4 100644
--- a/includes/Forms/MetadataMappingForm.php
+++ b/includes/Forms/MetadataMappingForm.php
@@ -29,7 +29,6 @@
* an html form
*/
public static function getForm( FormHandler $Handler, array
&$user_options ) {
-
$linkRenderer =
MediaWikiServices::getInstance()->getLinkRenderer();
$template_link = '[[Template:' .
Utils::sanitizeString(
$user_options['gwtoolset-mediawiki-template-name'] ) .
diff --git a/includes/Handlers/UploadHandler.php
b/includes/Handlers/UploadHandler.php
index 6437b7b..16817ca 100644
--- a/includes/Handlers/UploadHandler.php
+++ b/includes/Handlers/UploadHandler.php
@@ -286,7 +286,7 @@
* url is to a script that returns the media file
* $url = https://www.rijksmuseum.nl/mediabin.jsp?id=RP-P-1956-764
* $url =
'http://europeanastatic.eu/api/image?uri=http%3A%2F%2Fcollections.smvk.se
-
%3A8080%2Fcarlotta-em%2Fguest%2F1422401%2F13%2Fbild.jpg&size=LARGE&type=IMAGE';
+ *
%3A8080%2Fcarlotta-em%2Fguest%2F1422401%2F13%2Fbild.jpg&size=LARGE&type=IMAGE';
*
* url is redirected to another url that actually serves the media file
* $url = 'http://www.rijksmuseum.nl/media/assets/AK-RAK-1978-3';
@@ -746,7 +746,6 @@
public function saveMediafileViaJob(
array $user_options, array $options, array $whitelisted_post
) {
-
if ( count( $this->mediafile_jobs ) >
(int)$user_options['gwtoolset-mediafile-throttle'] ) {
throw new MWException(
wfMessage( 'gwtoolset-developer-issue' )
diff --git a/includes/Handlers/Xml/XmlMappingHandler.php
b/includes/Handlers/Xml/XmlMappingHandler.php
index 3f11e35..2d19574 100644
--- a/includes/Handlers/Xml/XmlMappingHandler.php
+++ b/includes/Handlers/Xml/XmlMappingHandler.php
@@ -148,7 +148,6 @@
// cycle over all of the elements in the record element provided
foreach ( $DOMNodeList as $DOMNodeElement ) {
-
// if the current element is not one that was mapped,
skip it
if ( !array_key_exists(
$DOMNodeElement->tagName,
diff --git a/includes/Helpers/WikiChecks.php b/includes/Helpers/WikiChecks.php
index 0c7e461..50fc29f 100644
--- a/includes/Helpers/WikiChecks.php
+++ b/includes/Helpers/WikiChecks.php
@@ -186,7 +186,6 @@
* @return {Status}
*/
public static function pageIsReadyForThisUser( SpecialPage $SpecialPage
) {
-
$Status = self::verifyXMLReaderExists();
if ( !$Status->ok ) {
return $Status;
diff --git a/includes/Jobs/UploadMediafileJob.php
b/includes/Jobs/UploadMediafileJob.php
index fa7044a..ceb3424 100755
--- a/includes/Jobs/UploadMediafileJob.php
+++ b/includes/Jobs/UploadMediafileJob.php
@@ -77,7 +77,7 @@
$oldUser = $wgUser;
$wgUser = $this->User;
// This will automatically restore $wgUser, when
$magicScopeVariable falls out of scope.
- $magicScopeVariable = new ScopedCallback( function() use (
$oldUser ) {
+ $magicScopeVariable = new ScopedCallback( function () use (
$oldUser ) {
global $wgUser;
$wgUser = $oldUser;
} );
diff --git a/includes/Utils.php b/includes/Utils.php
index 2af1051..4e163bf 100644
--- a/includes/Utils.php
+++ b/includes/Utils.php
@@ -448,7 +448,7 @@
*
* @param {string} $title
*
- * @param {array} $options
+ * @param {array} $options
* @param {string} $options['replacement']
* the character used to replace illegal characters; defaults to ‘-’
*
diff --git a/maintenance/cleanupGWTFileBackend.php
b/maintenance/cleanupGWTFileBackend.php
index f9371e0..cb524cf 100644
--- a/maintenance/cleanupGWTFileBackend.php
+++ b/maintenance/cleanupGWTFileBackend.php
@@ -17,7 +17,7 @@
if ( $IP === false ) {
$IP = __DIR__ . '/../../..';
}
-require_once ( "$IP/maintenance/Maintenance.php" );
+require_once "$IP/maintenance/Maintenance.php";
/**
* Maintenance script to remove abandoned or outdated metadata files from the
temporary
diff --git a/phpcs.xml b/phpcs.xml
index e15fae1..de673c8 100644
--- a/phpcs.xml
+++ b/phpcs.xml
@@ -3,10 +3,21 @@
<rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki">
<exclude name="Generic.Files.LineLength"/>
<exclude name="PSR2.Classes.PropertyDeclaration.Underscore"/>
+ <exclude
name="MediaWiki.Commenting.FunctionComment.ExtraParamComment" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.MissingParamComment" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.MissingParamName" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.MissingParamTag" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.MissingReturn" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.ParamNameNoMatch" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.MissingDocumentationProtected" />
+ <exclude
name="MediaWiki.Commenting.FunctionComment.MissingDocumentationPublic" />
+ <exclude
name="MediaWiki.NamingConventions.LowerCamelFunctionsName.FunctionName" />
+ <exclude name="MediaWiki.Usage.SuperGlobalsUsage.SuperGlobals"
/>
+ <exclude
name="MediaWiki.WhiteSpace.SpaceBeforeSingleLineComment.NewLineComment" />
</rule>
<file>.</file>
- <arg name="encoding" value="UTF-8"/>
- <arg name="extensions" value="php,php5,inc"/>
+ <arg name="encoding" value="UTF-8" />
+ <arg name="extensions" value="php,php5,inc" />
<exclude-pattern>vendor</exclude-pattern>
<exclude-pattern>node_modules</exclude-pattern>
</ruleset>
--
To view, visit https://gerrit.wikimedia.org/r/360173
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Id98f147b80e9fa4a78eedf2b194c73f0dc10d11f
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/extensions/GWToolset
Gerrit-Branch: master
Gerrit-Owner: Legoktm <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: Umherirrender <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits