summaryrefslogtreecommitdiff
path: root/app/services/solidus_subscriptions/payment_failed_dispatcher.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/solidus_subscriptions/payment_failed_dispatcher.rb')
-rw-r--r--app/services/solidus_subscriptions/payment_failed_dispatcher.rb20
1 files changed, 0 insertions, 20 deletions
diff --git a/app/services/solidus_subscriptions/payment_failed_dispatcher.rb b/app/services/solidus_subscriptions/payment_failed_dispatcher.rb
deleted file mode 100644
index 29eb291..0000000
--- a/app/services/solidus_subscriptions/payment_failed_dispatcher.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-# frozen_string_literal: true
-
-# Handles payment failures for subscription installments.
-module SolidusSubscriptions
- class PaymentFailedDispatcher < Dispatcher
- def dispatch
- order.touch(:completed_at)
- order.cancel
- installments.each do |installment|
- installment.payment_failed!(order)
- end
-
- ::Spree::Event.fire(
- 'solidus_subscriptions.installments_failed_payment',
- installments: installments,
- order: order,
- )
- end
- end
-end