The return value of `civicrm_api*()` is generally `array`, but when used
with `getvalue` it can be scalar (specifically, `string` in this case).
This produces a type-warning in phan because it cannot tell that the true
return type is `string`.
$params['report_id'] = civicrm_api3('report_instance', 'getvalue', array('id' => $params['instance_id'], 'return' => 'report_id'));
}
- $class = civicrm_api3('option_value', 'getvalue', array(
+ $class = (string) civicrm_api3('option_value', 'getvalue', array(
'option_group_name' => 'report_template',
'return' => 'name',
'value' => $params['report_id'],