r105951 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r105950‎ | r105951 | r105952 >
Date:23:00, 12 December 2011
Author:reedy
Status:reverted
Tags:
Comment:
Reinstate 5 https live hacks
Modified paths:
  • /branches/wmf/1.18wmf1/extensions/CodeReview/backend/CodeRevision.php (modified) (history)

Diff [purge]

Index: branches/wmf/1.18wmf1/extensions/CodeReview/backend/CodeRevision.php
@@ -479,12 +479,18 @@
480480 // Get repo and build comment title (for url)
481481 $url = $this->getCanonicalUrl();
482482
 483+ // Live hack: always make the URL use https:
 484+ $url = str_replace( 'http:', 'https:', $url );
 485+
483486 foreach ( $res as $row ) {
484487 $revision = CodeRevision::newFromRow( $this->repo, $row );
485488 $users = $revision->getCommentingUsers();
486489
487490 $rowUrl = $revision->getCanonicalUrl();
488491
 492+ // Live hack: always make the URL use https:
 493+ $rowUrl = str_replace( 'http:', 'https:', $rowUrl );
 494+
489495 $revisionAuthor = $revision->getWikiUser();
490496
491497 $revisionCommitSummary = $revision->getMessage();
@@ -675,6 +681,9 @@
676682
677683 $url = $this->getCanonicalUrl( $commentId );
678684
 685+ // Live hack: always make the URL use https:
 686+ $url = str_replace( 'http:', 'https:', $url );
 687+
679688 $this->sendCommentToUDP( $commentId, $text, $url );
680689
681690 return $commentId;
@@ -1327,6 +1336,9 @@
13281337 if( $wgCodeReviewUDPAddress ) {
13291338 if( is_null( $url ) ) {
13301339 $url = $this->getCanonicalUrl( $commentId );
 1340+
 1341+ // Live hack: always make the URL use https:
 1342+ $url = str_replace( 'http:', 'https:', $url );
13311343 }
13321344
13331345 $line = wfMsg( 'code-rev-message' ) . " \00314(" . $this->repo->getName() .
@@ -1347,6 +1359,9 @@
13481360 if( $wgCodeReviewUDPAddress ) {
13491361 $url = $this->getCanonicalUrl();
13501362
 1363+ // Live hack: always make the URL use https:
 1364+ $url = str_replace( 'http:', 'https:', $url );
 1365+
13511366 $line = wfMsg( 'code-rev-status' ) . " \00314(" . $this->repo->getName() .
13521367 ")\00303 " . RecentChange::cleanupForIRC( $wgUser->getName() ) . "\003 " .
13531368 /* Remove three apostrophes as they are intended for the parser */

Status & tagging log