3 namespace MediaWiki\Page\Hook
;
5 use MediaWiki\Revision\RevisionRecord
;
6 use MediaWiki\User\UserIdentity
;
10 * This is a hook handler interface, see docs/Hooks.md.
11 * Use the hook name "RevisionFromEditComplete" to register handlers implementing this interface.
13 * @stable to implement
16 interface RevisionFromEditCompleteHook
{
18 * This hook is called when a revision was inserted due to an edit,
19 * file upload, import or page move.
23 * @param WikiPage $wikiPage WikiPage edited
24 * @param RevisionRecord $rev New revision
25 * @param int|false $originalRevId If the edit restores or repeats an earlier revision (such as a
26 * rollback or a null revision), the ID of that earlier revision. False otherwise.
27 * (Used to be called $baseID.)
28 * @param UserIdentity $user Editing user
29 * @param string[] &$tags Tags to apply to the edit and recent change. This is empty, and
30 * replacement is ignored, in the case of import or page move.
31 * @return bool|void True or no return value to continue or false to abort
33 public function onRevisionFromEditComplete( $wikiPage, $rev, $originalRevId,