function uc_wishlist_invoke_hook_add_to_cart in UC Wish List 6
Invoke hook_add_to_cart() in every module except uc_product_kit. We do this because that module adds the kit to the cart in that hook. It's probably s a bug.
1 call to uc_wishlist_invoke_hook_add_to_cart()
- uc_wishlist_add_item in ./
uc_wishlist.module - Adds an item to a user's wish list.
File
- ./
uc_wishlist.module, line 820 - Allows users to create public shopping/wish lists.
Code
function uc_wishlist_invoke_hook_add_to_cart() {
$args = func_get_args();
$hook = 'add_to_cart';
$return = array();
foreach (module_implements($hook) as $module) {
if ($module != 'uc_product_kit') {
$function = $module . '_' . $hook;
$result = call_user_func_array($function, $args);
if (isset($result) && is_array($result)) {
$return = array_merge_recursive($return, $result);
}
else {
if (isset($result)) {
$return[] = $result;
}
}
}
}
return $return;
}