Don't spew () when tools group is empty (as on last line where there can be no undo...
authorBrion Vibber <brion@users.mediawiki.org>
Wed, 11 Jul 2007 17:45:25 +0000 (17:45 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Wed, 11 Jul 2007 17:45:25 +0000 (17:45 +0000)
includes/PageHistory.php

index 7e7c541..a29492d 100644 (file)
@@ -262,7 +262,9 @@ class PageHistory {
                        $tools[] = "<span class=\"mw-history-undo\">{$undolink}</span>";
                }
                
-               $s .= ' (' . implode( ' | ', $tools ) . ')';
+               if( $tools ) {
+                       $s .= ' (' . implode( ' | ', $tools ) . ')';
+               }
                
                wfRunHooks( 'PageHistoryLineEnding', array( &$row , &$s ) );