Call getHtml on the content object, not TextContent
TextContent does not provide such a function, but it is possible that sub classes provides a protected function with this name. Bug: T292374 Change-Id: I56397a085226538a8156e0e7a195db463240624c
This commit is contained in:
parent
42a24c3e98
commit
fff8c0a44d
1 changed files with 1 additions and 1 deletions
|
|
@ -231,7 +231,7 @@ class TextContentHandler extends ContentHandler {
|
||||||
if ( $cpoParams->getGenerateHtml() ) {
|
if ( $cpoParams->getGenerateHtml() ) {
|
||||||
// Temporary changes as getHtml() is deprecated, we are working on removing usage of it.
|
// Temporary changes as getHtml() is deprecated, we are working on removing usage of it.
|
||||||
if ( method_exists( $content, 'getHtml' ) ) {
|
if ( method_exists( $content, 'getHtml' ) ) {
|
||||||
$method = new ReflectionMethod( 'TextContent', 'getHtml' );
|
$method = new ReflectionMethod( $content, 'getHtml' );
|
||||||
$method->setAccessible( true );
|
$method->setAccessible( true );
|
||||||
$html = $method->invoke( $content );
|
$html = $method->invoke( $content );
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue