API page: http://api.drupal.org/api/drupal/core%21modules%21aggregator%21aggregato...

Enter a descriptive title (above) relating to hook_aggregator_process_info, then describe the problem you have found:

As far as I can tell, hook_aggregator_process_info() is never invoked with a $feed argument. Yet the docs for D7 and D8 have such an (undocumented) argument. I think it should be removed... the only invocation I see is in aggregator_admin_form() and it doesn't pass in $feed.

Although this is purely a documentation issue, I'm putting it temporarily in the aggregator module component so the maintainers can comment on whether the $feed argument to the hook should or shouldn't be there (maybe there's an invocation that api.drupal.org is not picking up?).

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dozymoe’s picture

Looks like the $feed argument for hook_aggregator_process_info() is a typo, started here Pluggable architecture for aggregator.module.

At first it was hook_aggregator_process($op, $feed = NULL) with $opt being 'save', 'unique', 'info', like it was in Drupal 6. Then each $op become its own hook functions while keeping the $feed argument.

In the original function, the $op == 'info' do not make use of the $feed argument:

    case 'info':
      return array(
        'title' => t('Aggregator Light'),
        'description' => t('Creates lightweight records of feed items.'),
     );

Also, the aggregator module itself implements hook_aggregator_process_info() without $feed argument.

/**
 * Implementation of hook_aggregator_process_info().
 */
function aggregator_aggregator_process_info() {
  return array(
    'title' => t('Default processor'),
    'description' => t('Creates lightweight records from feed items.'),
  );
}
ParisLiakos’s picture

Title: hook_aggregator_process_info() - remove $feed from docs? » hook_aggregator_process_info() - remove $feed from docs
Version: 8.x-dev » 7.x-dev
Component: aggregator.module » documentation
Issue tags: +Novice
chertzog’s picture

Status: Active » Needs review
FileSize
523 bytes

Here's a patch.

ParisLiakos’s picture

Status: Needs review » Reviewed & tested by the community

thanks!

jhodgdon’s picture

Assigned: Unassigned » jhodgdon

Yes, thanks! I'll get this committed shortly.

jhodgdon’s picture

Assigned: jhodgdon » Unassigned
Status: Reviewed & tested by the community » Fixed

Thanks again - committed to 7.x.

Automatically closed -- issue fixed for 2 weeks with no activity.