From 1267fc6f36373b50d6124a6123810ac69f126dc3 Mon Sep 17 00:00:00 2001 From: Roan Kattouw Date: Sun, 20 Nov 2011 18:17:49 +0000 Subject: [PATCH] (bug 24037) Add byte length of revision to Special:Contributions. Patch by Umherirrender --- RELEASE-NOTES-1.19 | 1 + includes/specials/SpecialContributions.php | 8 +++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/RELEASE-NOTES-1.19 b/RELEASE-NOTES-1.19 index f04b0479e1..b92622d9e7 100644 --- a/RELEASE-NOTES-1.19 +++ b/RELEASE-NOTES-1.19 @@ -90,6 +90,7 @@ production. for an IP address redirects to the contributions list for that IP * (bug 8859) Database::update should take array of tables too * (bug 19698) Inverse selection for Special:Contributions +* (bug 24037) Add byte length of revision to Special:Contributions === Bug fixes in 1.19 === * $wgUploadNavigationUrl should be used for file redlinks if diff --git a/includes/specials/SpecialContributions.php b/includes/specials/SpecialContributions.php index a86bb29b1d..6c732cb344 100644 --- a/includes/specials/SpecialContributions.php +++ b/includes/specials/SpecialContributions.php @@ -712,6 +712,12 @@ class ContribsPager extends ReverseChronologicalPager { $mflag = ''; } + if ( !is_null( $rev->getSize() ) && !$rev->isDeleted( Revision::DELETED_TEXT ) ) { + $mSize = $this->getSkin()->formatRevisionSize( $rev->getSize() ); + } else { + $mSize = ''; + } + // Don't show useless link to people who cannot hide revisions $canHide = $user->isAllowed( 'deleterevision' ); if( $canHide || ($rev->getVisibility() && $user->isAllowed('deletedhistory')) ) { @@ -732,7 +738,7 @@ class ContribsPager extends ReverseChronologicalPager { } $diffHistLinks = '(' . $difftext . $this->messages['pipe-separator'] . $histlink . ')'; - $ret = "{$del}{$d} {$diffHistLinks}{$chardiff}{$nflag}{$mflag} {$link}{$userlink} {$comment} {$topmarktext}"; + $ret = "{$del}{$d} {$diffHistLinks}{$chardiff}{$nflag}{$mflag} {$link}{$userlink} {$mSize} {$comment} {$topmarktext}"; # Denote if username is redacted for this edit if( $rev->isDeleted( Revision::DELETED_USER ) ) { -- 2.20.1