Index: trunk/tools/analysis/StreamingXMLHistory.php |
— | — | @@ -234,7 +234,17 @@ |
235 | 235 | $isNew = "no"; |
236 | 236 | |
237 | 237 | $revertIndex = array_search($md5, $this->md5History); |
238 | | - |
| 238 | + if($revertIndex === FALSE ){ |
| 239 | + $isNew = 'yes'; |
| 240 | + $this->revTypes[] = new Edit(true); |
| 241 | + } |
| 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; |
| 248 | + |
239 | 249 | $csvData = array( |
240 | 250 | $revision->id, |
241 | 251 | strtotime($revision->timestamp), |
— | — | @@ -260,19 +270,7 @@ |
261 | 271 | $this->nextLog = $this->getNextLogDataLine(); |
262 | 272 | } |
263 | 273 | } |
264 | | - fputcsv($this->outputFile, $csvData); |
265 | | - |
266 | | - if($revertIndex === FALSE ){ |
267 | | - $isNew = 'yes'; |
268 | | - $this->revTypes[] = new Edit(true); |
269 | | - } |
270 | | - else{ |
271 | | - $revert = new Revert(count($this->revTypes), $this->revTypes, true, $revertIndex); |
272 | | - $this->revTypes[] = $revert; |
273 | | - $revert->updateHistory(); |
274 | | - } |
275 | | - $this->md5History[] = $md5; |
276 | | - |
| 274 | + fputcsv($this->outputFile, $csvData); |
277 | 275 | } |
278 | 276 | |
279 | 277 | |