dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Introduce ContentHandler::getSecondaryDataUpdates.
[lhc/web/wiklou.git]
/
includes
/
content
/
AbstractContent.php
diff --git
a/includes/content/AbstractContent.php
b/includes/content/AbstractContent.php
index
b21eadc
..
733d85a
100644
(file)
--- a/
includes/content/AbstractContent.php
+++ b/
includes/content/AbstractContent.php
@@
-43,7
+43,7
@@
abstract class AbstractContent implements Content {
protected $model_id;
/**
protected $model_id;
/**
- * @param string $modelId
+ * @param string
|null
$modelId
*
* @since 1.21
*/
*
* @since 1.21
*/
@@
-145,7
+145,7
@@
abstract class AbstractContent implements Content {
/**
* @since 1.21
*
/**
* @since 1.21
*
- * @param string $format
+ * @param string
|null
$format
*
* @return string
*
*
* @return string
*
@@
-182,7
+182,7
@@
abstract class AbstractContent implements Content {
/**
* @since 1.21
*
/**
* @since 1.21
*
- * @param Content $that
+ * @param Content
|null
$that
*
* @return bool
*
*
* @return bool
*
@@
-219,9
+219,9
@@
abstract class AbstractContent implements Content {
* @since 1.21
*
* @param Title $title
* @since 1.21
*
* @param Title $title
- * @param Content $old
+ * @param Content
|null
$old
* @param bool $recursive
* @param bool $recursive
- * @param ParserOutput $parserOutput
+ * @param ParserOutput
|null
$parserOutput
*
* @return DataUpdate[]
*
*
* @return DataUpdate[]
*
@@
-501,10
+501,11
@@
abstract class AbstractContent implements Content {
ParserOptions $options = null, $generateHtml = true
) {
if ( $options === null ) {
ParserOptions $options = null, $generateHtml = true
) {
if ( $options === null ) {
- $options =
$this->getContentHandler()->makeParserOptions
( 'canonical' );
+ $options =
ParserOptions::newCanonical
( 'canonical' );
}
$po = new ParserOutput();
}
$po = new ParserOutput();
+ $options->registerWatcher( [ $po, 'recordOption' ] );
if ( Hooks::run( 'ContentGetParserOutput',
[ $this, $title, $revId, $options, $generateHtml, &$po ] )
if ( Hooks::run( 'ContentGetParserOutput',
[ $this, $title, $revId, $options, $generateHtml, &$po ] )
@@
-518,6
+519,7
@@
abstract class AbstractContent implements Content {
}
Hooks::run( 'ContentAlterParserOutput', [ $this, $title, $po ] );
}
Hooks::run( 'ContentAlterParserOutput', [ $this, $title, $po ] );
+ $options->registerWatcher( null );
return $po;
}
return $po;
}