r52694 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r52693‎ | r52694 | r52695 >
Date:14:03, 2 July 2009
Author:ashley
Status:deferred
Tags:
Comment:
follow-up to r52676: remove unnecessary use of extract(), per code review
Modified paths:
  • /trunk/extensions/WikiCategoryTagCloud/WikiCategoryTagCloud.php (modified) (history)

Diff [purge]

Index: trunk/extensions/WikiCategoryTagCloud/WikiCategoryTagCloud.php
@@ -63,7 +63,6 @@
6464 $INCREASE_FACTOR = 100;
6565
6666 $dbr = wfGetDB( DB_SLAVE );
67 - extract( $dbr->tableNames( 'categorylinks' ) );
6867
6968 $cloud_style = @$params['style'];
7069 $cloud_classes = preg_split( '/\s+/', @$params['class'] );
@@ -100,7 +99,7 @@
101100 }
102101 }
103102
104 - $sql = "SELECT cl_to as title, COUNT(*) as count FROM $categorylinks " . $exclude_condition . " GROUP BY cl_to HAVING count >= $min_count_input ORDER BY cl_to ASC";
 103+ $sql = "SELECT cl_to as title, COUNT(*) as count FROM {$dbr->tableName( 'categorylinks' )} " . $exclude_condition . " GROUP BY cl_to HAVING count >= $min_count_input ORDER BY cl_to ASC";
105104
106105 $res = $dbr->query( $sql );
107106 $count = $dbr->numRows( $res );
@@ -144,4 +143,4 @@
145144 return htmlspecialchars( $matches[1] );
146145 }
147146 }
148 -}
 147+}
\ No newline at end of file

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r52676cleanup to WikiCategoryTagCloudashley05:06, 2 July 2009

Status & tagging log