- if (empty($params['id']) && empty($params['payment_instrument_id'])) {
- $params['payment_instrument_id'] = civicrm_api3('PaymentProcessorType', 'getvalue', [
- 'id' => $params['payment_processor_type_id'],
- 'return' => 'payment_instrument_id',
- ]);
- }