mirror of
https://github.com/meineerde/redmine.git
synced 2025-12-19 15:01:14 +00:00
code cleanup: rubocop: fix Layout/CaseIndentation in lib/redmine/views/builders.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@18723 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
e34eb2d89c
commit
57923d0450
@ -71,7 +71,6 @@ Layout/CaseIndentation:
|
||||
- 'config/initializers/10-patches.rb'
|
||||
- 'lib/redmine/helpers/gantt.rb'
|
||||
- 'lib/redmine/menu_manager.rb'
|
||||
- 'lib/redmine/views/builders.rb'
|
||||
|
||||
# Cop supports --auto-correct.
|
||||
Layout/ClosingHeredocIndentation:
|
||||
|
||||
@ -24,12 +24,13 @@ module Redmine
|
||||
module Views
|
||||
module Builders
|
||||
def self.for(format, request, response, &block)
|
||||
builder = case format
|
||||
builder =
|
||||
case format
|
||||
when 'xml', :xml then Builders::Xml.new(request, response)
|
||||
when 'json', :json then Builders::Json.new(request, response)
|
||||
else
|
||||
raise "No builder for format #{format}"
|
||||
end
|
||||
end
|
||||
if block
|
||||
block.call(builder)
|
||||
else
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user