Available from version 1.13
Get warnings when renaming an user
Define function:
public static function onRenameUserWarning( $oldName, $newName, &$warnings ) { ... }
Attach hook: In extension.json:
	"Hooks": {
		"RenameUserWarning": "MyExtensionHooks::onRenameUserWarning"
Called from: File(s): Renameuser extension
Interface: RenameUserWarningHook.php

For more information about attaching hooks, see Manual:Hooks .
For examples of extensions using this hook, see Category:RenameUserWarning extensions.

Details edit

  • $oldName: old name
  • $newName: new name
  • &$warnings: array of warning (messages names, may be with parameters)