Index: trunk/extensions/CodeReview/ui/CodeRevisionView.php |
— | — | @@ -573,17 +573,21 @@ |
574 | 574 | */ |
575 | 575 | protected function formatSignoffs( $signOffs, $showButtons ) { |
576 | 576 | $this->showButtonsFormatSignoffs = $showButtons; |
577 | | - $signoffs = implode( "\n", |
578 | | - array_map( array( $this, 'formatSignoffInline' ), $signOffs ) |
579 | | - ); |
580 | 577 | |
581 | 578 | $header = ''; |
582 | | - if ( $showButtons ) { |
583 | | - $header = '<th></th>'; |
| 579 | + if ( count( $signOffs ) ) { |
| 580 | + if ( $showButtons ) { |
| 581 | + $header = '<th></th>'; |
| 582 | + } |
| 583 | + $signoffs = implode( "\n", |
| 584 | + array_map( array( $this, 'formatSignoffInline' ), $signOffs ) |
| 585 | + ); |
| 586 | + $header .= '<th>' . wfMsgHtml( 'code-signoff-field-user' ) . '</th>'; |
| 587 | + $header .= '<th>' . wfMsgHtml( 'code-signoff-field-flag' ). '</th>'; |
| 588 | + $header .= '<th>' . wfMsgHtml( 'code-signoff-field-date' ). '</th>'; |
| 589 | + } else { |
| 590 | + $signoffs = ''; |
584 | 591 | } |
585 | | - $header .= '<th>' . wfMsgHtml( 'code-signoff-field-user' ) . '</th>'; |
586 | | - $header .= '<th>' . wfMsgHtml( 'code-signoff-field-flag' ). '</th>'; |
587 | | - $header .= '<th>' . wfMsgHtml( 'code-signoff-field-date' ). '</th>'; |
588 | 592 | $buttonrow = $showButtons ? $this->signoffButtons( $signOffs ) : ''; |
589 | 593 | return "<table border='1' class='wikitable'><tr>$header</tr>$signoffs$buttonrow</table>"; |
590 | 594 | } |