function _commerce_file_license_property_duration_remaining in Commerce File 7
Remaining Callback for License duration
Parameters
$license: The Commerce File License entity
Return value
The current value of the property
1 string reference to '_commerce_file_license_property_duration_remaining'
File
- ./
commerce_file.commerce.inc, line 102 - Implementations of Commerce Hooks
Code
function _commerce_file_license_property_duration_remaining($license, $limit_value) {
if (is_numeric($limit_value)) {
$current = _commerce_file_license_property_duration_current($license);
if (isset($current)) {
return $limit_value - $current;
}
// default to full limit
return $limit_value;
}
return 0;
}