Hello,
I am trying to alter the line item title as specified in this related support request:
https://drupal.org/node/2091693
But it's not working. It seems like hook_commerce_line_item_type_info_alter is being called but not the title callback:
/**
* Implimentation of hook_commerce_line_item_type_info_alter()
*
* Override the default title callback so we can use our own
*/
function client_specific_commerce_line_item_type_info_alter(&$line_item_types) {
$line_item_types['product']['callbacks'] = array('title' => '_client_specific_commerce_product_line_item_title');
}
/**
* Returns an appropriate title for this line item
*/
function _client_specific_commerce_product_line_item_title($line_item) {
dsm($line_item);
return 'HELLO!';
}
Anyone know what might be going on?
Thanks
Comments
Comment #1
rszrama commentedLooks fine to me. Did you clear the cache after adding the hook?
Comment #2
bander2 commentedI did and I know the hook is being called because I can see output of dsm, but not in the title callback.