r88911 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r88910‎ | r88911 | r88912 >
Date:18:41, 26 May 2011
Author:btongminh
Status:ok (Comments)
Tags:
Comment:
Follow-up r81536: Fix misleading comment in Status and add a comment to LocalFileRestoreBatch::cleanupFailedBatch.
Modified paths:
  • /trunk/phase3/includes/Status.php (modified) (history)
  • /trunk/phase3/includes/filerepo/LocalFile.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Status.php
@@ -18,7 +18,7 @@
1919
2020 /** Counters for batch operations */
2121 public $successCount = 0, $failCount = 0;
22 - /** Array to indicate which items of the batch operations failed */
 22+ /** Array to indicate which items of the batch operations were successful */
2323 public $success = array();
2424
2525 /*semi-private*/ var $errors = array();
Index: trunk/phase3/includes/filerepo/LocalFile.php
@@ -1947,6 +1947,13 @@
19481948 return $status;
19491949 }
19501950
 1951+ /**
 1952+ * Cleanup a failed batch. The batch was only partially successful, so
 1953+ * rollback by removing all items that were succesfully copied.
 1954+ *
 1955+ * @param Status $storeStatus
 1956+ * @param array $storeBatch
 1957+ */
19511958 function cleanupFailedBatch( $storeStatus, $storeBatch ) {
19521959 $cleanupBatch = array();
19531960

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r81536(bug 19751) Filesystem is now checked during image undeletion...btongminh20:54, 4 February 2011

Comments

#Comment by Hashar (talk | contribs)   16:39, 6 June 2011

tagging for 1.17 inclusion since it followup r81536 which fixes a possible data lost

Status & tagging log