diff -u drupalorg_search/drupalorg_search.module drupalorg_search/drupalorg_search.module --- drupalorg_search/drupalorg_search.module 10 Aug 2010 16:58:33 -0000 +++ drupalorg_search/drupalorg_search.module 10 Aug 2010 18:14:13 -0000 @@ -359,10 +359,10 @@ 'im_vid_' . _project_get_vid(), 'im_project_release_api_tids', ), - // Filters are set below via explicity calls to add_filter rather than + // Filters are set below via explicit calls to add_filter() rather than // here in the $params array. This is because any filters passed to - // apachesolr_drupal_query will override filters set via the $params array - // during the prepare_query invocation. + // apachesolr_drupal_query() will override filters set via the $params + // array during the prepare_query() invocation. 'fq' => array(), 'facet' => 'true', 'facet.mincount' => 1, @@ -378,8 +378,8 @@ $function_name($query, $params, 'drupalorg_search_execute_base_query'); } - // We add our fields after the prepare_query because prepare_query - // generates a call to parse_filters which destroys anything that + // We add our fields after the prepare_query() because prepare_query() + // generates a call to parse_filters() which destroys anything that // does not get passed into the query on construction. // We explicitly filter the blocks to only show projects with the module tid // associated. These values are not passed in the url, so we add them here @@ -476,7 +476,7 @@ * potentially submit to other urls if desired. * * @param string $path - * The base path to which the version form will be redirect. + * The base path to which the version form will redirect. */ function drupalorg_search_version_form(&$form_state, $path) { $query = apachesolr_current_query(); @@ -484,7 +484,7 @@ $form = array(); // Add version select field to our form. - project_solr_add_version_field($form, $query, 'drupal_core', 'Show only modules for Drupal version'); + $form['drupal_core'] = project_solr_get_api_version_field($query, t('Show only modules for Drupal version')); $form['path'] = array( '#type' => 'value', @@ -498,11 +498,11 @@ } /** - * Create a query, add the selected version filter, and redirect to the relevant page. + * Create a query with the right version filter and redirect to the right page. * - * Create a new query, remove the version filter if it exists, - * add any new version filtering if it exists, and direct back to the relevant - * page with the appropriate filter string. + * Create a new query, add any version filtering if it was selected in the + * form, and redirect back to the relevant page with the appropriate filter + * string. */ function drupalorg_search_version_form_submit($form, &$form_state) { // We create a new query with our base path so that we don't need to remove