Merge "Add 路面 for better word segmentation."
[lhc/web/wiklou.git] / includes / specials / SpecialNewpages.php
index 44097c8..1798e8f 100644 (file)
@@ -294,6 +294,8 @@ class SpecialNewpages extends IncludableSpecialPage {
         * @return String
         */
        public function formatRow( $result ) {
+               $title = Title::newFromRow( $result );
+
                # Revision deletion works on revisions, so we should cast one
                $row = array(
                                          'comment' => $result->rc_comment,
@@ -302,13 +304,13 @@ class SpecialNewpages extends IncludableSpecialPage {
                                          'user' => $result->rc_user,
                                        );
                $rev = new Revision( $row );
+               $rev->setTitle( $title );
 
                $classes = array();
 
                $lang = $this->getLanguage();
                $dm = $lang->getDirMark();
 
-               $title = Title::newFromRow( $result );
                $spanTime = Html::element( 'span', array( 'class' => 'mw-newpages-time' ),
                        $lang->userTimeAndDate( $result->rc_timestamp, $this->getUser() )
                );
@@ -343,7 +345,7 @@ class SpecialNewpages extends IncludableSpecialPage {
                        $this->msg( 'parentheses' )->rawParams( $histLink )->escaped() );
 
                $length = Html::element( 'span', array( 'class' => 'mw-newpages-length' ),
-                               '[' . $this->msg( 'nbytes' )->numParams( $result->length )->text() . ']'
+                       $this->msg( 'brackets' )->params( $this->msg( 'nbytes' )->numParams( $result->length )->text() )
                );
 
                $ulink = Linker::revUserTools( $rev );