Index: trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php |
— | — | @@ -1416,23 +1416,25 @@ |
1417 | 1417 | * @param string $action |
1418 | 1418 | * @param object $title |
1419 | 1419 | * @param array $params |
| 1420 | + * @param string $comment |
| 1421 | + * @param string $rv (review links) |
1420 | 1422 | * @return bool true |
1421 | 1423 | */ |
1422 | | - public static function reviewLogLine( $type='', $action='', $title=null, $params=array() ) { |
| 1424 | + public static function reviewLogLine( $type, $action, $title=null, $params=array(), &$comment, &$rv ) { |
1423 | 1425 | $actionsValid = array('approve','approve2','approve-a','approve2-a','unapprove','unapprove2'); |
1424 | 1426 | # Show link to page with oldid=x |
1425 | | - if( $type == 'review' && in_array($action,$actionsValid) && is_object($title) && isset($params[0]) ) { |
| 1427 | + if( $type == 'review' && is_object($title) && in_array($action,$actionsValid) && isset($params[0]) ) { |
1426 | 1428 | global $wgUser; |
1427 | 1429 | # Load required messages |
1428 | 1430 | wfLoadExtensionMessages( 'FlaggedRevs' ); |
1429 | 1431 | # Don't show diff if param missing or rev IDs are the same |
1430 | 1432 | if( !empty($params[1]) && $params[0] != $params[1] ) { |
1431 | | - $r = '(' . $wgUser->getSkin()->makeKnownLinkObj( $title, wfMsgHtml('review-logentry-diff'), |
| 1433 | + $rv = '(' . $wgUser->getSkin()->makeKnownLinkObj( $title, wfMsgHtml('review-logentry-diff'), |
1432 | 1434 | "oldid={$params[1]}&diff={$params[0]}") . ') '; |
1433 | 1435 | } else { |
1434 | | - $r = '(' . wfMsgHtml('review-logentry-diff') . ')'; |
| 1436 | + $rv = '(' . wfMsgHtml('review-logentry-diff') . ')'; |
1435 | 1437 | } |
1436 | | - $r .= ' (' . $wgUser->getSkin()->makeKnownLinkObj( $title, |
| 1438 | + $rv .= ' (' . $wgUser->getSkin()->makeKnownLinkObj( $title, |
1437 | 1439 | wfMsgHtml('review-logentry-id',$params[0]), |
1438 | 1440 | "oldid={$params[0]}&diff=prev&diffonly=0") . ')'; |
1439 | 1441 | } |