Merge "Update Hook call"
This commit is contained in:
commit
6b62c5d7d7
|
@ -401,7 +401,13 @@ class MathTexvc extends MathRenderer {
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getPng() {
|
public function getPng() {
|
||||||
|
// Workaround for bugfix for Bug 56769
|
||||||
|
if ( !isset( $wgHooks['ParserAfterParse']['FlushMathBackend'] ) ) {
|
||||||
|
// saves the PNG-file
|
||||||
|
Hooks::run( 'ParserAfterParse' );
|
||||||
|
}
|
||||||
$backend = $this->getBackend();
|
$backend = $this->getBackend();
|
||||||
return $backend->getFileContents( array( 'src' => $this->getHashPath() . "/" . $this->getHash() . '.png' ) );
|
return $backend->getFileContents( array( 'src' => $this->getHashPath() . "/" . $this->getHash() . '.png' ) );
|
||||||
}
|
}
|
||||||
|
|
|
@ -93,11 +93,6 @@ class SpecialMathShowImage extends SpecialPage {
|
||||||
}
|
}
|
||||||
if ( $success ) {
|
if ( $success ) {
|
||||||
if ( $this->mode == MW_MATH_PNG ) {
|
if ( $this->mode == MW_MATH_PNG ) {
|
||||||
// Workaround for bugfix for Bug 56769
|
|
||||||
if ( !isset( $wgHooks['ParserAfterParse']['FlushMathBackend'] ) ) {
|
|
||||||
// saves the PNG-file
|
|
||||||
wfRunHooks('ParserAfterParse');
|
|
||||||
}
|
|
||||||
$output = $this->renderer->getPng();
|
$output = $this->renderer->getPng();
|
||||||
} else {
|
} else {
|
||||||
$output = $this->renderer->getSvg();
|
$output = $this->renderer->getSvg();
|
||||||
|
|
Loading…
Reference in New Issue