In order to allow multiple votes on the same content for a single user (https://drupal.org/node/1006630) we are using hook_rate_vote_alter to set $context['criteria'] = array();

This revealed that hook_rate_vote_alter is actually not able to change anything in $context; see https://api.drupal.org/api/drupal/includes!common.inc/function/drupal_al... -- specifically the part about $data['__drupal_alter_by_ref']

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

petermallett’s picture

Status: Active » Needs review
FileSize
447 bytes

Here's my patch to fix the invocation of drupal_alter to allow alteration of both parameters.

petermallett’s picture

Version: 6.x-2.x-dev » 6.x-1.x-dev
lamp5’s picture

Status: Needs review » Closed (outdated)