function _uc_stripe_get_stripe_plugins in Ubercart Stripe 8.3
Same name and namespace in other branches
- 8.2 uc_stripe.install \_uc_stripe_get_stripe_plugins()
@file Installation file for the uc_stripe module.
1 call to _uc_stripe_get_stripe_plugins()
- uc_stripe_requirements in ./
uc_stripe.install - Implements hook_requirements().
File
- ./
uc_stripe.install, line 9 - Installation file for the uc_stripe module.
Code
function _uc_stripe_get_stripe_plugins() {
$plugin_data = [];
$payment_method_names = \Drupal::configFactory()
->listAll('uc_payment.method');
foreach ($payment_method_names as $method) {
$config = \Drupal::config($method);
$data = $config
->get();
if ($data['plugin'] == 'stripe_gateway') {
$plugin_data[$data['id']] = $data;
}
}
return $plugin_data;
}