Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

dirty fix store_credit_callback

  • Loading branch information...
commit 287eee48a1b5784ee785f506478dcf9bdb4f3b5e 1 parent 9d2c8fd
@sbounmy sbounmy authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  app/controllers/spree/checkout_controller_decorator.rb
View
2  app/controllers/spree/checkout_controller_decorator.rb
@@ -147,6 +147,8 @@ def paypal_finish
@order.update_attribute(:state, "complete")
state_callback(:after) # So that after_complete is called, setting session[:order_id] to nil
+ @order.consume_users_credit #since we dont rely on state machine callback, we just explicitly call this method for spree_store_credits
+
@order.finalize!
flash[:notice] = I18n.t(:order_processed_successfully)
redirect_to completion_route
Please sign in to comment.
Something went wrong with that request. Please try again.