From 14a5eee41c1b9d529d3ddf4d67e9ad3b8a37f7f3 Mon Sep 17 00:00:00 2001 From: Raphael Date: Tue, 19 Oct 2010 17:29:22 -0700 Subject: [PATCH] Return if there is a failure to create a user --- app/controllers/registrations_controller.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/controllers/registrations_controller.rb b/app/controllers/registrations_controller.rb index 970bdca5b..75745a0ab 100644 --- a/app/controllers/registrations_controller.rb +++ b/app/controllers/registrations_controller.rb @@ -9,6 +9,7 @@ class RegistrationsController < Devise::RegistrationsController rescue MongoMapper::DocumentNotValid => e flash[:error] = e.message redirect_to new_user_registration_path + return end if user.save flash[:notice] = I18n.t 'registrations.create.success'