mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/TitleBlacklist
synced 2024-11-24 06:04:05 +00:00
Avoid using ContentHandler::getContentText()
ContentHandler::getContentText() is deprecated and should be replaced with Content::getText() for TextContent instances. Change-Id: If38508a069c668e43686226262acbb8ecce92764
This commit is contained in:
parent
83a24f0f2d
commit
d54338f52b
|
@ -137,7 +137,8 @@ class TitleBlacklist {
|
|||
} else {
|
||||
$page = WikiPage::factory( $title );
|
||||
if ( $page->exists() ) {
|
||||
return ContentHandler::getContentText( $page->getContent() );
|
||||
$content = $page->getContent();
|
||||
return ( $content instanceof TextContent ) ? $content->getText() : "";
|
||||
}
|
||||
}
|
||||
} elseif ( $source['type'] == 'url' && count( $source ) >= 2 ) {
|
||||
|
|
Loading…
Reference in a new issue