spree/spree — pull request #4542 by shioyama (2014-04-04 03:21:42+00:00)
Title: Ensure transition to payment processing state happens outside transaction

The current method for preventing double payment submissions is simply not working, because the payment state is set in a transaction (see discusion in #4499). This PR turns off transactions on the order state machine and in addition aliases `save_state` to `save` to make this work (see [these inline notes](https://github.com/pluginaweek/state_machine/blob/fb0259ea5aa17b2924a7007d6d1e2a12f743a301/lib/state_machine/integrations/active_record.rb#L139) for more details on why this is necessary).