From: mlitn Date: Tue, 3 Jul 2012 17:38:09 +0000 (-0700) Subject: Pass $classes in the ContributionsLineEnding hook X-Git-Tag: 1.31.0-rc.0~23160^2 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/?a=commitdiff_plain;h=1c757557b0290b086a8a205d5b2c6ded48f26690;p=lhc%2Fweb%2Fwiklou.git Pass $classes in the ContributionsLineEnding hook Originally part of https://gerrit.wikimedia.org/r/13880 Change-Id: I05d9d13e8dc4e9442ecfba79a7d1af8bf192c28b --- diff --git a/docs/hooks.txt b/docs/hooks.txt index 37444623fc..7df2c39d7e 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -705,8 +705,9 @@ $user: user (object) whose email is being confirmed 'ContributionsLineEnding': Called before a contributions HTML line is finished $page: SpecialPage object for contributions -$ret: the HTML line +&$ret: the HTML line $row: the DB row for this line +&$classes: the classes to add to the surrounding
  • 'ContributionsToolLinks': Change tool links above Special:Contributions $id: User identifier diff --git a/includes/specials/SpecialContributions.php b/includes/specials/SpecialContributions.php index 94650371e2..50192ac922 100644 --- a/includes/specials/SpecialContributions.php +++ b/includes/specials/SpecialContributions.php @@ -866,7 +866,7 @@ class ContribsPager extends ReverseChronologicalPager { $ret .= " $tagSummary"; // Let extensions add data - wfRunHooks( 'ContributionsLineEnding', array( &$this, &$ret, $row ) ); + wfRunHooks( 'ContributionsLineEnding', array( $this, &$ret, $row, &$classes ) ); $classes = implode( ' ', $classes ); $ret = "
  • $ret
  • \n";