From dd1aed2930cec6ec6b464ebd75d1f9ddf76f924f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gerg=C5=91=20Tisza?= Date: Wed, 27 May 2020 15:44:59 +0200 Subject: [PATCH] Replace hard-deprecated WikiPage::getRevision call in generateSampleNotifications.php ...but keep soft-deprecated WikiPage::doEditContent because no realistic replacement exists :/ Change-Id: Iee8c2fcfcbd5cb8c15854b1ada9eb691a2197658 --- maintenance/generateSampleNotifications.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/maintenance/generateSampleNotifications.php b/maintenance/generateSampleNotifications.php index 2cd4b1b10..3e8ecff19 100644 --- a/maintenance/generateSampleNotifications.php +++ b/maintenance/generateSampleNotifications.php @@ -215,9 +215,9 @@ class GenerateSampleNotifications extends Maintenance { $page = WikiPage::factory( $title ); $previousContent = ""; $page->loadPageData( WikiPage::READ_LATEST ); - $revision = $page->getRevision(); + $revision = $page->getRevisionRecord(); if ( $revision ) { - $content = $revision->getContent( RevisionRecord::FOR_PUBLIC ); + $content = $revision->getContent( SlotRecord::MAIN, RevisionRecord::FOR_PUBLIC ); if ( $content instanceof WikitextContent ) { $previousContent = $content->getText(); }