From 54c6202b625601a16661a34ba930eaa471315974 Mon Sep 17 00:00:00 2001 From: Mark Moser Date: Wed, 14 Sep 2016 17:29:09 -0500 Subject: [PATCH] removed unreachable code --- app/controllers/quiz_controller.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controllers/quiz_controller.rb b/app/controllers/quiz_controller.rb index 8010d32..4523f10 100644 --- a/app/controllers/quiz_controller.rb +++ b/app/controllers/quiz_controller.rb @@ -27,8 +27,9 @@ class QuizController < ApplicationController def submit_summary not_completed_error = 'You must complete all questions to submit your test.' redirect_to :summary, flash: { error: not_completed_error } and return unless prep_status.can_submit - redirect_to :thankyou and return if complete_and_email - redirect_to :summary, flash: { error: 'Sorry, there was a problem. Please try again.' } + + complete_and_email + redirect_to :thankyou end private