Skip to content
Snippets Groups Projects
Commit 0c094d12 authored by totten's avatar totten
Browse files

CRM-13165 - api/v3/utils - Don't mandate that all "MONEY" fields be non-null

----------------------------------------
* CRM-13165: hrjob: Re-save produces blocking error, "X is not a valid amount"
  http://issues.civicrm.org/jira/browse/CRM-13165
parent 43de7088
Branches
Tags
No related merge requests found
......@@ -1093,7 +1093,7 @@ function _civicrm_api3_validate_fields($entity, $action, &$params, $errorMode =
break;
case CRM_Utils_Type::T_MONEY:
if (!CRM_Utils_Rule::money($params[$fieldName])) {
if (!CRM_Utils_Rule::money($params[$fieldName]) && !empty($params[$fieldName])) {
throw new Exception($fieldName . " is not a valid amount: " . $params[$fieldName]);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment