Umherirrender has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/384237 )
Change subject: Improve some parameter docs ...................................................................... Improve some parameter docs Change-Id: Iee2b635f3c9b9e891c615e12bbd18cce27f9b577 --- M Renameuser.hooks.php M RenameuserSQL.php M maintenance/renameUserCleanup.php M phpcs.xml M specials/SpecialRenameuser.php 5 files changed, 19 insertions(+), 22 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Renameuser refs/changes/37/384237/1 diff --git a/Renameuser.hooks.php b/Renameuser.hooks.php index 225eba7..d6861c4 100644 --- a/Renameuser.hooks.php +++ b/Renameuser.hooks.php @@ -5,7 +5,7 @@ * Show a log if the user has been renamed and point to the new username. * Don't show the log if the $oldUserName exists as a user. * - * @param $article Article + * @param Article $article * @return bool */ public static function onShowMissingArticle( $article ) { @@ -37,9 +37,9 @@ /** * Shows link to Special:Renameuser on Special:Contributions/foo * - * @param $id - * @param $nt Title - * @param $tools + * @param int $id + * @param Title $nt + * @param array &$tools * * @return bool */ diff --git a/RenameuserSQL.php b/RenameuserSQL.php index 0d8ddcb..12b7ada 100644 --- a/RenameuserSQL.php +++ b/RenameuserSQL.php @@ -83,11 +83,11 @@ /** * Constructor * - * @param $old string The old username - * @param $new string The new username - * @param $uid + * @param string $old The old username + * @param string $new The new username + * @param int $uid * @param User $renamer - * @param $options array Optional extra options. + * @param array $options Optional extra options. * 'reason' - string, reason for the rename * 'debugPrefix' - string, prefixed to debug messages * 'checkIfUserExists' - bool, whether to update the user table @@ -161,6 +161,7 @@ /** * Do the rename operation + * @return true */ public function rename() { global $wgAuth, $wgUpdateRowsPerJob; diff --git a/maintenance/renameUserCleanup.php b/maintenance/renameUserCleanup.php index 74ec452..a1ec1d7 100644 --- a/maintenance/renameUserCleanup.php +++ b/maintenance/renameUserCleanup.php @@ -170,7 +170,7 @@ /** * @param User $olduser * @param User $newuser - * @param $uid + * @param int $uid */ public function doUpdates( $olduser, $newuser, $uid ) { $this->updateTable( @@ -231,12 +231,12 @@ /** * @param string $table - * @param $usernamefield - * @param $useridfield - * @param $timestampfield + * @param string $usernamefield + * @param string $useridfield + * @param string $timestampfield * @param User $olduser * @param User $newuser - * @param $uid + * @param int $uid */ public function updateTable( $table, $usernamefield, $useridfield, $timestampfield, $olduser, $newuser, $uid diff --git a/phpcs.xml b/phpcs.xml index 7dd11fc..2f3f4aa 100644 --- a/phpcs.xml +++ b/phpcs.xml @@ -2,9 +2,6 @@ <ruleset> <rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki"> <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.Files.ClassMatchesFilename.NotMatch" /> <exclude name="MediaWiki.Files.ClassMatchesFilename.WrongCase" /> <exclude name="MediaWiki.Commenting.FunctionComment.MissingDocumentationProtected" /> @@ -12,10 +9,9 @@ <exclude name="MediaWiki.WhiteSpace.SpaceBeforeSingleLineComment.NewLineComment" /> </rule> <rule ref="Generic.Files.LineLength"> - <exclude-pattern>Renameuser.alias.php</exclude-pattern> + <exclude-pattern>Renameuser\.alias\.php</exclude-pattern> </rule> <file>.</file> <arg name="extensions" value="php,php5,inc" /> - <arg name="encoding" value="utf8" /> - <exclude-pattern>vendor</exclude-pattern> + <arg name="encoding" value="UTF-8" /> </ruleset> diff --git a/specials/SpecialRenameuser.php b/specials/SpecialRenameuser.php index 89fbe34..a847ba2 100644 --- a/specials/SpecialRenameuser.php +++ b/specials/SpecialRenameuser.php @@ -390,9 +390,9 @@ } /** - * @param $username Title - * @param $type - * @param $out OutputPage + * @param Title $username + * @param string $type + * @param OutputPage &$out */ protected function showLogExtract( $username, $type, &$out ) { # Show relevant lines from the logs: -- To view, visit https://gerrit.wikimedia.org/r/384237 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iee2b635f3c9b9e891c615e12bbd18cce27f9b577 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Renameuser Gerrit-Branch: master Gerrit-Owner: Umherirrender <umherirrender_de...@web.de> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits