From ef85b03a1d13f998ae9bce255d3dd63c78426517 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Fri, 22 Jan 2021 16:12:34 +0100 Subject: [PATCH] Use double quotes everywhere --- lib/generators/rails/templates/controller.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/generators/rails/templates/controller.rb b/lib/generators/rails/templates/controller.rb index 6dba877..5aeeff0 100644 --- a/lib/generators/rails/templates/controller.rb +++ b/lib/generators/rails/templates/controller.rb @@ -33,7 +33,7 @@ def create respond_to do |format| if @<%= orm_instance.save %> - format.html { redirect_to @<%= singular_table_name %>, notice: <%= "'#{human_name} was successfully created.'" %> } + format.html { redirect_to @<%= singular_table_name %>, notice: <%= %("#{human_name} was successfully created.") %> } format.json { render :show, status: :created, location: <%= "@#{singular_table_name}" %> } else format.html { render :new } @@ -47,7 +47,7 @@ def create def update respond_to do |format| if @<%= orm_instance.update("#{singular_table_name}_params") %> - format.html { redirect_to @<%= singular_table_name %>, notice: <%= "'#{human_name} was successfully updated.'" %> } + format.html { redirect_to @<%= singular_table_name %>, notice: <%= %("#{human_name} was successfully updated.") %> } format.json { render :show, status: :ok, location: <%= "@#{singular_table_name}" %> } else format.html { render :edit } @@ -61,7 +61,7 @@ def update def destroy @<%= orm_instance.destroy %> respond_to do |format| - format.html { redirect_to <%= index_helper %>_url, notice: <%= "'#{human_name} was successfully destroyed.'" %> } + format.html { redirect_to <%= index_helper %>_url, notice: <%= %("#{human_name} was successfully destroyed.") %> } format.json { head :no_content } end end