diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 8ecb68d388..55e5736dca 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -153,7 +153,7 @@ class ApplicationController < ActionController::Base current_order.empty! current_order.set_order_cycle! nil flash[:info] = I18n.t('order_cycle_closed') - redirect_to main_app.root_url + redirect_to main_app.shop_path end end diff --git a/spec/controllers/base_controller_spec.rb b/spec/controllers/base_controller_spec.rb index 2f82f52e7d..02b68b3750 100644 --- a/spec/controllers/base_controller_spec.rb +++ b/spec/controllers/base_controller_spec.rb @@ -100,7 +100,7 @@ describe BaseController, type: :controller do end end - it "redirects to home with message if order cycle is expired" do + it "redirects to shopfront with message if order cycle is expired" do expect(controller).to receive(:current_order_cycle).and_return(oc) expect(controller).to receive(:current_order).and_return(order).twice expect(oc).to receive(:closed?).and_return(true) @@ -109,7 +109,7 @@ describe BaseController, type: :controller do get :index - expect(response).to redirect_to root_url + expect(response).to redirect_to shop_url expect(flash[:info]).to eq I18n.t('order_cycle_closed') end end