This hook was introduced in 1.35 and the EditResult parameter makes $originalRevId and $undidRevId params redundant. I also uploaded cross-repo dependent patches for extensions that already use this hook. Bug: T254074 Depends-On: I3922d9a92242c9a6469058a2a2c2a95891e9e429 Depends-On: I52e7d6198c000100e9c1013ebc865c1f9b836fe4 Change-Id: I551702327c6e2b6dab9e0eda52f03ebb9382d050
39 lines
1.1 KiB
PHP
39 lines
1.1 KiB
PHP
<?php
|
|
|
|
namespace MediaWiki\Storage\Hook;
|
|
|
|
use MediaWiki\Revision\RevisionRecord;
|
|
use MediaWiki\Storage\EditResult;
|
|
use MediaWiki\User\UserIdentity;
|
|
use WikiPage;
|
|
|
|
/**
|
|
* @stable for implementation
|
|
* @ingroup Hooks
|
|
*/
|
|
interface PageSaveCompleteHook {
|
|
/**
|
|
* This hook is called after an article has been updated.
|
|
*
|
|
* @since 1.35
|
|
*
|
|
* @param WikiPage $wikiPage WikiPage modified
|
|
* @param UserIdentity $user User performing the modification
|
|
* @param string $summary Edit summary/comment
|
|
* @param int $flags Flags passed to WikiPage::doEditContent()
|
|
* @param RevisionRecord $revisionRecord New RevisionRecord of the article
|
|
* @param EditResult $editResult Object storing information about the effects of this edit,
|
|
* including which edits were reverted and which edit is this based on (for reverts and null
|
|
* edits).
|
|
* @return bool|void True or no return value to continue or false to stop other hook handlers
|
|
* from being called; save cannot be aborted
|
|
*/
|
|
public function onPageSaveComplete(
|
|
$wikiPage,
|
|
$user,
|
|
$summary,
|
|
$flags,
|
|
$revisionRecord,
|
|
$editResult
|
|
);
|
|
}
|