Physikerwelt has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/189348

Change subject: Update hook to new extension registration mechanism
......................................................................

Update hook to new extension registration mechanism

* Use revision-id rather than page-id for the hook.
   The page-id can be derived from the revision id but not
   the other way round. And since formulae may change
   if a new revision is created revision id is more appropriate.

Change-Id: I201f80bbee16617ef88417a2430261167aaca4ae
---
M Math.hooks.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Math 
refs/changes/48/189348/1

diff --git a/Math.hooks.php b/Math.hooks.php
index c9e6482..6b01b0c 100644
--- a/Math.hooks.php
+++ b/Math.hooks.php
@@ -124,10 +124,10 @@
                        wfDebugLog( "Math" , "Rendering failed. Printing error 
message." );
                        return $renderer->getLastError();
                }
-               wfRunHooks( 'MathFormulaRendered',
+               Hooks::run( 'MathFormulaRendered',
                        array( &$renderer,
                                &$renderedMath,
-                               $parser->getTitle()->getArticleID(),
+                               $parser->getRevisionId(),
                                $parser->nextLinkID() ) );// Enables indexing 
of math formula
                if ( $mode == MW_MATH_MATHJAX || $mode == MW_MATH_LATEXML_JAX ) 
{
                        $parser->getOutput()->addModules( array( 
'ext.math.mathjax.enabler' ) );

-- 
To view, visit https://gerrit.wikimedia.org/r/189348
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I201f80bbee16617ef88417a2430261167aaca4ae
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Math
Gerrit-Branch: master
Gerrit-Owner: Physikerwelt <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to