]> source.dussan.org Git - redmine.git/commitdiff
use "do end" instead of {} at AttachmentsController
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 6 Nov 2020 13:00:52 +0000 (13:00 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 6 Nov 2020 13:00:52 +0000 (13:00 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@20278 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/controllers/attachments_controller.rb

index f47da554e55fdcbf94e45703d7aea8b0b134e18b..0f78662a83e3d50c0ee719edd501f7881914b045 100644 (file)
@@ -37,7 +37,7 @@ class AttachmentsController < ApplicationController
 
   def show
     respond_to do |format|
-      format.html {
+      format.html do
         if @attachment.container.respond_to?(:attachments)
           @attachments = @attachment.container.attachments.to_a
           if index = @attachments.index(@attachment)
@@ -64,7 +64,7 @@ class AttachmentsController < ApplicationController
         else
           render :action => 'other'
         end
-      }
+      end
       format.api
     end
   end
@@ -113,13 +113,13 @@ class AttachmentsController < ApplicationController
 
     respond_to do |format|
       format.js
-      format.api {
+      format.api do
         if saved
           render :action => 'upload', :status => :created
         else
           render_validation_errors(@attachment)
         end
-      }
+      end
     end
   end
 
@@ -155,13 +155,13 @@ class AttachmentsController < ApplicationController
     saved = @attachment.save
 
     respond_to do |format|
-      format.api {
+      format.api do
         if saved
           render_api_ok
         else
           render_validation_errors(@attachment)
         end
-      }
+      end
     end
   end