r73302 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r73301‎ | r73302 | r73303 >
Date:04:38, 19 September 2010
Author:svemir
Status:deferred
Tags:
Comment:
add missing comments
remove unused groupby code
update version number to match SF repository
Modified paths:
  • /trunk/extensions/SphinxSearch/SphinxSearch.php (modified) (history)
  • /trunk/extensions/SphinxSearch/SphinxSearch_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SphinxSearch/SphinxSearch_body.php
@@ -124,6 +124,12 @@
125125 return $categories;
126126 }
127127
 128+ /**
 129+ * $wgAjaxExportList callback - create a category filter sub-menu
 130+ *
 131+ * @param string $parent_id
 132+ * @return string
 133+ */
128134 function ajaxGetCategoryChildren( $parent_id ) {
129135
130136 $title = Title::newFromID( $parent_id );
@@ -159,6 +165,11 @@
160166 return $response;
161167 }
162168
 169+ /**
 170+ * Main execution function
 171+ *
 172+ * @param string $par Parameters passed to the page
 173+ */
163174 function execute( $par ) {
164175 global $wgRequest, $wgOut, $wgUser, $wgSphinxMatchAll, $wgSphinxSearch_index_list;
165176
@@ -226,6 +237,11 @@
227238 $this->createNewSearchForm( $term );
228239 }
229240
 241+ /**
 242+ * If an exact title match can be found, jump straight ahead to it.
 243+ *
 244+ * @param string $term
 245+ */
230246 function goResult( $term ) {
231247 global $wgOut, $wgGoToEdit;
232248
@@ -387,9 +403,6 @@
388404 $cl->SetFilter( 'category', $this->exc_categories, true );
389405 }
390406
391 - if ( isset( $wgSphinxSearch_groupby ) && isset( $wgSphinxSearch_groupsort ) ) {
392 - $cl->SetGroupBy( $wgSphinxSearch_groupby, SPH_GROUPBY_ATTR, $wgSphinxSearch_groupsort );
393 - }
394407 $cl->SetSortMode( $wgSphinxSearch_sortmode, $wgSphinxSearch_sortby );
395408 $cl->SetLimits(
396409 ( $this->page - 1 ) * $wgSphinxSearch_matches,
Index: trunk/extensions/SphinxSearch/SphinxSearch.php
@@ -11,7 +11,7 @@
1212
1313 $wgExtensionCredits['specialpage'][] = array(
1414 'path' => __FILE__,
15 - 'version' => '0.7.0',
 15+ 'version' => '0.7.1',
1616 'name' => 'SphinxSearch',
1717 'author' => array( 'Svemir Brkic', 'Paul Grinberg' ),
1818 'email' => 'svemir at deveblog dot com, gri6507 at yahoo dot com',

Status & tagging log