Drop ContentHandler::makeParserOptions(), deprecated in 1.32
Change-Id: I2d22cc8cd8fee9d8bb8b8dcdd050b64da17ac5ad
This commit is contained in:
parent
cff372b149
commit
9082d22754
3 changed files with 3 additions and 22 deletions
|
|
@ -214,6 +214,8 @@ because of Phabricator reports.
|
||||||
* OutputPage::parse() and OutputPage::parseInline(), deprecated in 1.32, have
|
* OutputPage::parse() and OutputPage::parseInline(), deprecated in 1.32, have
|
||||||
been removed. Use ::parseAsContent() or ::parseAsInterface(), as
|
been removed. Use ::parseAsContent() or ::parseAsInterface(), as
|
||||||
appropriate.
|
appropriate.
|
||||||
|
* ContentHandler::makeParserOptions(), deprecated in 1.32, was removed. Use
|
||||||
|
WikiPage::makeParserOptions() or ParserOptions::newCanonical() instead.
|
||||||
* …
|
* …
|
||||||
|
|
||||||
=== Deprecations in 1.35 ===
|
=== Deprecations in 1.35 ===
|
||||||
|
|
|
||||||
|
|
@ -73,7 +73,7 @@ Also, the old `Article::getContent()` (which returns text) is superceded by `Art
|
||||||
|
|
||||||
Code that relies on a textual representation of the page content should eventually be rewritten. However, `ContentHandler::getContentText()` provides a stop-gap that can be used to get text for a page. Its behavior is controlled by `$wgContentHandlerTextFallback`; per default it will return the text for text based content, and null for any other content.
|
Code that relies on a textual representation of the page content should eventually be rewritten. However, `ContentHandler::getContentText()` provides a stop-gap that can be used to get text for a page. Its behavior is controlled by `$wgContentHandlerTextFallback`; per default it will return the text for text based content, and null for any other content.
|
||||||
|
|
||||||
For rendering page content, `Content::getParserOutput()` should be used instead of accessing the parser directly. `ContentHandler::makeParserOptions()` can be used to construct appropriate options.
|
For rendering page content, `Content::getParserOutput()` should be used instead of accessing the parser directly. `WikiPage::makeParserOptions()` can be used to construct appropriate options.
|
||||||
|
|
||||||
Besides some functions, some hooks have also been replaced by new versions (see hooks.txt for details). These hooks will now trigger a warning when used:
|
Besides some functions, some hooks have also been replaced by new versions (see hooks.txt for details). These hooks will now trigger a warning when used:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1190,27 +1190,6 @@ abstract class ContentHandler {
|
||||||
return $undone_content;
|
return $undone_content;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Get parser options suitable for rendering and caching the article
|
|
||||||
*
|
|
||||||
* @deprecated since 1.32, use WikiPage::makeParserOptions() or
|
|
||||||
* ParserOptions::newCanonical() instead.
|
|
||||||
* @param IContextSource|User|string $context One of the following:
|
|
||||||
* - IContextSource: Use the User and the Language of the provided
|
|
||||||
* context
|
|
||||||
* - User: Use the provided User object and $wgLang for the language,
|
|
||||||
* so use an IContextSource object if possible.
|
|
||||||
* - 'canonical': Canonical options (anonymous user with default
|
|
||||||
* preferences and content language).
|
|
||||||
*
|
|
||||||
* @throws MWException
|
|
||||||
* @return ParserOptions
|
|
||||||
*/
|
|
||||||
public function makeParserOptions( $context ) {
|
|
||||||
wfDeprecated( __METHOD__, '1.32' );
|
|
||||||
return ParserOptions::newCanonical( $context );
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns true for content models that support caching using the
|
* Returns true for content models that support caching using the
|
||||||
* ParserCache mechanism. See WikiPage::shouldCheckParserCache().
|
* ParserCache mechanism. See WikiPage::shouldCheckParserCache().
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue