function _uc_file_accumulate_limits in Ubercart 7.3
Same name and namespace in other branches
- 8.4 uc_file/uc_file.module \_uc_file_accumulate_limits()
- 6.2 uc_file/uc_file.module \_uc_file_accumulate_limits()
Accumulates limits and store them to the file_user array.
2 calls to _uc_file_accumulate_limits()
- uc_file_uc_add_to_cart in uc_file/
uc_file.module - Implements hook_uc_add_to_cart().
- uc_file_user_renew in uc_file/
uc_file.module - Adds file(s) to a user's list of downloadable files, accumulating limits.
File
- uc_file/
uc_file.module, line 1029 - Allows products to be associated with downloadable files.
Code
function _uc_file_accumulate_limits(&$file_user, $file_limits, $force_overwrite) {
// Accumulate numerics.
_uc_file_number_accumulate_equation($file_user['download_limit'], $file_limits['download_limit'], $force_overwrite);
_uc_file_number_accumulate_equation($file_user['address_limit'], $file_limits['address_limit'], $force_overwrite);
// Accumulate time.
_uc_file_time_accumulate_equation($file_user['expiration'], $file_limits['expiration'], $force_overwrite);
}