function uc_discounts_add_to_existing_map_number_value in Ubercart Discounts (Alternative) 6.2
Same name and namespace in other branches
- 7.2 uc_discounts/uc_discounts.module \uc_discounts_add_to_existing_map_number_value()
1 call to uc_discounts_add_to_existing_map_number_value()
- get_discounts_for_order in uc_discounts/
uc_discounts.module - Returns discounts for order. Note: $order->uc_discounts_codes must be set
File
- uc_discounts/
uc_discounts.module, line 2186
Code
function uc_discounts_add_to_existing_map_number_value(&$a, $key, $value) {
$a[$key] = array_key_exists($key, $a) ? $a[$key] + $value : $value;
}