mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Remove redundant code.
This commit is contained in:
parent
dbbcc8388a
commit
dbacaff1c3
1 changed files with 2 additions and 3 deletions
|
@ -32,9 +32,8 @@ module ActionDispatch
|
||||||
end
|
end
|
||||||
|
|
||||||
def render_html(status)
|
def render_html(status)
|
||||||
found = false
|
path = "#{public_path}/#{status}.#{I18n.locale}.html"
|
||||||
path = "#{public_path}/#{status}.#{I18n.locale}.html" if I18n.locale
|
path = "#{public_path}/#{status}.html" unless (found = File.exist?(path))
|
||||||
path = "#{public_path}/#{status}.html" unless path && (found = File.exist?(path))
|
|
||||||
|
|
||||||
if found || File.exist?(path)
|
if found || File.exist?(path)
|
||||||
render_format(status, 'text/html', File.read(path))
|
render_format(status, 'text/html', File.read(path))
|
||||||
|
|
Loading…
Reference in a new issue