class Pay::Stripe::Customer

def charge(amount, options = {})

Charges an amount to the customer's default payment method
def charge(amount, options = {})
  args = {confirm: true, payment_method: default_payment_method&.processor_id}.merge(options)
  payment_intent = create_payment_intent(amount, args)
  Pay::Payment.new(payment_intent).validate
  charge = payment_intent.latest_charge
  Pay::Stripe::Charge.sync(charge.id, object: charge)
rescue ::Stripe::StripeError => e
  raise Pay::Stripe::Error, e
end