Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only run transition callbacks if order state is cart #2959

Closed
wants to merge 1 commit into from

Conversation

huoxito
Copy link
Member

@huoxito huoxito commented May 2, 2013

Calling order.next_transition.run_callbacks with order in payment state
might raise

undefined method `run_callbacks' for nil:NilClass

And we only need to call that manually when changing from cart to
address, fixes #2921

Please let me know if I missed anything or it breaks the build. I've only run controllers and the checkout feature spec.

Calling order.next_transition.run_callbacks with order in payment state
might raise

  undefined method `run_callbacks' for nil:NilClass

And we only need to call that manually when changing from cart to
address, fixes spree#2921
@huoxito
Copy link
Member Author

huoxito commented May 2, 2013

btw I think 1-3-stable needs this too.

@huoxito
Copy link
Member Author

huoxito commented May 4, 2013

@CodeSavvy The error it tries to fix regards the first order state transition, usually cart -> address, I don't think it's related to the fact you removed the delivery step. Also please tell what it's not working for you exactly.

@abdul-shajin
Copy link
Contributor

@huoxito I thought #2966 (comment) this bug is due to this reason..and I've mistaken..sorry for this

@radar
Copy link
Contributor

radar commented May 6, 2013

@huoxito This patch does not apply cleanly to 1-3-stable. Can you please port over your changes to spec/requests/checkout_spec.rb into the 1-3-stable branch as well?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

undefined method `run_callbacks' for nil:NilClass during checkout
3 participants