r108314 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r108313‎ | r108314 | r108315 >
Date:10:07, 7 January 2012
Author:nikerabbit
Status:ok (Comments)
Tags:
Comment:
Just shuptup the error instead, I have no interested in finding out why Lqt has lost track of some of it's threads
Modified paths:
  • /trunk/extensions/LiquidThreads/classes/View.php (modified) (history)

Diff [purge]

Index: trunk/extensions/LiquidThreads/classes/View.php
@@ -170,11 +170,12 @@
171171 $changed_thread = $revision->getChangeObject();
172172 $curr_rev_id = $changed_thread->rootRevision();
173173 $curr_rev = Revision::newFromId( $curr_rev_id );
174 - if ( !$curr_rev ) {
175 - throw new MWException( "Undefined revision in diffQuery" );
 174+
 175+ $oldid = '';
 176+ if ( $curr_rev ) {
 177+ $prev_rev = $curr_rev->getPrevious();
 178+ $oldid = $prev_rev ? $prev_rev->getId() : '';
176179 }
177 - $prev_rev = $curr_rev->getPrevious();
178 - $oldid = $prev_rev ? $prev_rev->getId() : "";
179180
180181 $query = array(
181182 'lqt_method' => 'diff',

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r108311Throw an exception to aid debuggingnikerabbit09:27, 7 January 2012

Comments

#Comment by Hashar (talk | contribs)   12:03, 7 January 2012

reverts r108311

Status & tagging log