From a99e18990d229716d7ec82b0bde17ffe89f47ade Mon Sep 17 00:00:00 2001 From: Rohan Mitchell Date: Wed, 4 Jun 2014 14:27:17 +1000 Subject: [PATCH] Readability --- app/controllers/checkout_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/checkout_controller.rb b/app/controllers/checkout_controller.rb index 3879f16741..95fc059e06 100644 --- a/app/controllers/checkout_controller.rb +++ b/app/controllers/checkout_controller.rb @@ -26,7 +26,7 @@ class CheckoutController < Spree::CheckoutController if @order.next state_callback(:after) else - unless @order.errors.empty? + if @order.errors.present? flash[:error] = @order.errors.full_messages.to_sentence else flash[:error] = t(:payment_processing_failed)