r108746 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r108745‎ | r108746 | r108747 >
Date:19:44, 12 January 2012
Author:aaron
Status:ok
Tags:
Comment:
Minor type cleanups
Modified paths:
  • /branches/FileBackend/phase3/includes/filerepo/backend/SwiftFileBackend.php (modified) (history)

Diff [purge]

Index: branches/FileBackend/phase3/includes/filerepo/backend/SwiftFileBackend.php
@@ -592,11 +592,11 @@
593593 /**
594594 * Get a connection to the swift proxy
595595 *
596 - * @return CF_Connection|null
 596+ * @return CF_Connection|false
597597 */
598598 protected function getConnection() {
599599 if ( $this->conn === false ) {
600 - return null; // failed last attempt
 600+ return false; // failed last attempt
601601 }
602602 // Authenticate with proxy and get a session key.
603603 // Session keys expire after a while, so we renew them periodically.
@@ -638,7 +638,7 @@
639639 class SwiftFileIterator implements Iterator {
640640 /** @var Array */
641641 protected $bufferIter = array();
642 - protected $bufferAfter = ''; // string; list items *after* this path
 642+ protected $bufferAfter = null; // string; list items *after* this path
643643 protected $pos = 0; // integer
644644
645645 /** @var SwiftFileBackend */
@@ -685,7 +685,7 @@
686686
687687 public function rewind() {
688688 $this->pos = 0;
689 - $this->bufferAfter = '';
 689+ $this->bufferAfter = null;
690690 $this->bufferIter = $this->backend->getFileListPageInternal(
691691 $this->container, $this->dir, $this->bufferAfter, self::PAGE_SIZE
692692 );

Status & tagging log