Remove unused variables
authorSam Reed <reedy@users.mediawiki.org>
Fri, 18 Feb 2011 01:10:38 +0000 (01:10 +0000)
committerSam Reed <reedy@users.mediawiki.org>
Fri, 18 Feb 2011 01:10:38 +0000 (01:10 +0000)
includes/LinksUpdate.php
includes/filerepo/FSRepo.php
includes/installer/PostgresInstaller.php
includes/specials/SpecialFileDuplicateSearch.php
includes/upload/UploadBase.php
skins/MonoBook.php

index b86ea56..a800fdf 100644 (file)
@@ -67,7 +67,7 @@ class LinksUpdate {
                        $this->mInterlangs[$key] = $title;
                }
 
-               foreach ( $this->mCategories as $cat => &$sortkey ) {
+               foreach ( $this->mCategories as &$sortkey ) {
                        # If the sortkey is longer then 255 bytes,
                        # it truncated by DB, and then doesn't get
                        # matched when comparing existing vs current
index a3419e6..d992986 100644 (file)
@@ -268,7 +268,7 @@ class FSRepo extends FileRepo {
         * @param $pairs array Pair of (zone, rel) pairs to delete
         */
        function cleanupBatch( $pairs ) {
-               foreach ( $pairs as $i => $pair ) {
+               foreach ( $pairs as $pair ) {
                        list( $zone, $rel ) = $pair;
                        $root = $this->getZonePath( $zone );
                        $path = "$root/$rel";
index f73350e..8ebd394 100644 (file)
@@ -274,7 +274,6 @@ class PostgresInstaller extends DatabaseInstaller {
                        return $status;
                }
 
-               $db = $this->getVar( 'wgDBname' );
                $schema = $this->getVar( 'wgDBmwschema' );
                $safeuser = $this->db->addIdentifierQuotes( $this->getVar( 'wgDBuser' ) );
                $safeusercheck = $this->db->addQuotes( $this->getVar( 'wgDBuser' ) );
index 6b282c6..2e4b608 100644 (file)
@@ -68,7 +68,7 @@ class FileDuplicateSearchPage extends QueryPage {
                $html = array();
                $html[] = $this->openList( 0 );
 
-               foreach ( $dupes as $key => $dupe ) {
+               foreach ( $dupes as $dupe ) {
                        $line = $this->formatResult( $skin, $dupe );
                        $html[] = "<li>" . $line . "</li>";
                }
index ea065a7..a517b5a 100644 (file)
@@ -443,7 +443,6 @@ abstract class UploadBase {
 
                $localFile = $this->getLocalFile();
                $filename = $localFile->getName();
-               $n = strrpos( $filename, '.' );
 
                /**
                 * Check whether the resulting filename is different from the desired one,
index 11052b7..d594a86 100644 (file)
@@ -65,7 +65,6 @@ class MonoBookTemplate extends BaseTemplate {
                global $wgRequest;
 
                $this->skin = $skin = $this->data['skin'];
-               $action = $wgRequest->getText( 'action' );
 
                // Suppress warnings to prevent notices about missing indexes in $this->data
                wfSuppressWarnings();