r70538 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r70537‎ | r70538 | r70539 >
Date:04:18, 6 August 2010
Author:dfinzer
Status:deferred
Tags:
Comment:
Fixed issue with misaligned status column
Modified paths:
  • /trunk/tools/analysis/StreamingXMLHistory.php (modified) (history)

Diff [purge]

Index: trunk/tools/analysis/StreamingXMLHistory.php
@@ -231,19 +231,14 @@
232232 $textSize = strlen($revision->text);
233233
234234 $md5 = md5($revision->text);
 235+
 236+ $revertIndex = array_search($md5, $this->md5History);
 237+
235238 $isNew = "no";
236239
237 - $revertIndex = array_search($md5, $this->md5History);
238240 if($revertIndex === FALSE ){
239 - $isNew = 'yes';
240 - $this->revTypes[] = new Edit(true);
 241+ $isNew = "yes";
241242 }
242 - else{
243 - $revert = new Revert(count($this->revTypes), $this->revTypes, true, $revertIndex);
244 - $this->revTypes[] = $revert;
245 - $revert->updateHistory();
246 - }
247 - $this->md5History[] = $md5;
248243
249244 $csvData = array(
250245 $revision->id,
@@ -270,10 +265,18 @@
271266 $this->nextLog = $this->getNextLogDataLine();
272267 }
273268 }
274 - fputcsv($this->outputFile, $csvData);
 269+ fputcsv($this->outputFile, $csvData);
 270+
 271+ if($revertIndex === FALSE ){
 272+ $this->revTypes[] = new Edit(true);
 273+ }
 274+ else{
 275+ $revert = new Revert(count($this->revTypes), $this->revTypes, true, $revertIndex);
 276+ $this->revTypes[] = $revert;
 277+ $revert->updateHistory();
 278+ }
 279+ $this->md5History[] = $md5;
275280 }
276 -
277 -
278281 }
279282
280283

Status & tagging log