diff --git a/app/controllers/domains_controller.rb b/app/controllers/domains_controller.rb index 260d204d..9ecd2b58 100644 --- a/app/controllers/domains_controller.rb +++ b/app/controllers/domains_controller.rb @@ -52,7 +52,7 @@ def create respond_to do |format| format.html { render :action => :new } - format.all { render :text => t(:message_domain_name_exists), :status => :unprocessable_entity } + format.all { render :json => @domain.errors, :status => :unprocessable_entity } end return diff --git a/config/locales/en.yml b/config/locales/en.yml index 0743e82a..e88e8161 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -512,7 +512,6 @@ en: message_domain_created: "Domain created" message_domain_updated: "Domain updated" message_domain_macro_applied: "Macro applied to domain" - message_domain_name_exists: "Duplicate domain name exists" # macro_steps_controller message_macro_step_removed: "Macro step removed"