mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-13 17:57:21 +00:00
Merge "Replace hard-deprecated WikiPage::getRevision call in generateSampleNotifications.php"
This commit is contained in:
commit
bf3aeb1280
|
@ -215,9 +215,9 @@ class GenerateSampleNotifications extends Maintenance {
|
||||||
$page = WikiPage::factory( $title );
|
$page = WikiPage::factory( $title );
|
||||||
$previousContent = "";
|
$previousContent = "";
|
||||||
$page->loadPageData( WikiPage::READ_LATEST );
|
$page->loadPageData( WikiPage::READ_LATEST );
|
||||||
$revision = $page->getRevision();
|
$revision = $page->getRevisionRecord();
|
||||||
if ( $revision ) {
|
if ( $revision ) {
|
||||||
$content = $revision->getContent( RevisionRecord::FOR_PUBLIC );
|
$content = $revision->getContent( SlotRecord::MAIN, RevisionRecord::FOR_PUBLIC );
|
||||||
if ( $content instanceof WikitextContent ) {
|
if ( $content instanceof WikitextContent ) {
|
||||||
$previousContent = $content->getText();
|
$previousContent = $content->getText();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue