RevisionUndeleted hook: Add $oldPageId
Not always the same as the restored revision's pageId Bug: T248727 Change-Id: I4e3ea4519d34de7c67ad8999575affe77d756f08
This commit is contained in:
parent
c260233ff9
commit
5127acb8ec
2 changed files with 2 additions and 1 deletions
|
|
@ -2899,6 +2899,7 @@ $flags: DEPRECATED! Always null!
|
|||
|
||||
'RevisionUndeleted': After an article revision is restored.
|
||||
$revisionRecord: the RevisionRecord that was restored
|
||||
$oldPageID: the page ID of the revision when archived (may be null)
|
||||
|
||||
'SearchableNamespaces': An option to modify which namespaces are searchable.
|
||||
&$arr: Array of namespaces ($nsId => $name) which will be used.
|
||||
|
|
|
|||
|
|
@ -785,7 +785,7 @@ class PageArchive {
|
|||
|
||||
$restored++;
|
||||
|
||||
Hooks::run( 'RevisionUndeleted', [ $revision ] );
|
||||
Hooks::run( 'RevisionUndeleted', [ $revision, $row->ar_page_id ] );
|
||||
|
||||
// TODO: Hard deprecate after replacing uses with RevisionUndeleted
|
||||
// Deprecated since 1.35
|
||||
|
|
|
|||
Loading…
Reference in a new issue