diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2019-01-17 14:33:14 -0800 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2019-01-17 14:33:14 -0800 |
commit | 63d96adb685ae3cf464327c59a090ede25c55414 (patch) | |
tree | f9444ef6aa7637bb4618ba494a30dad26a2fbbef /actionpack/lib/action_controller/metal | |
parent | e1fe21f62454d72203f97f7328a74bb164781962 (diff) | |
download | rails-63d96adb685ae3cf464327c59a090ede25c55414.tar.gz rails-63d96adb685ae3cf464327c59a090ede25c55414.tar.bz2 rails-63d96adb685ae3cf464327c59a090ede25c55414.zip |
Remove args from `default_render`
It's always called with 0 params, so just remove the parameter
Diffstat (limited to 'actionpack/lib/action_controller/metal')
-rw-r--r-- | actionpack/lib/action_controller/metal/basic_implicit_render.rb | 2 | ||||
-rw-r--r-- | actionpack/lib/action_controller/metal/implicit_render.rb | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/lib/action_controller/metal/basic_implicit_render.rb b/actionpack/lib/action_controller/metal/basic_implicit_render.rb index 2dc990f303..f9a758ff0e 100644 --- a/actionpack/lib/action_controller/metal/basic_implicit_render.rb +++ b/actionpack/lib/action_controller/metal/basic_implicit_render.rb @@ -6,7 +6,7 @@ module ActionController super.tap { default_render unless performed? } end - def default_render(*args) + def default_render head :no_content end end diff --git a/actionpack/lib/action_controller/metal/implicit_render.rb b/actionpack/lib/action_controller/metal/implicit_render.rb index d3bb58f48b..8365ddca57 100644 --- a/actionpack/lib/action_controller/metal/implicit_render.rb +++ b/actionpack/lib/action_controller/metal/implicit_render.rb @@ -30,9 +30,9 @@ module ActionController # :stopdoc: include BasicImplicitRender - def default_render(*args) + def default_render if template_exists?(action_name.to_s, _prefixes, variants: request.variant) - render(*args) + render elsif any_templates?(action_name.to_s, _prefixes) message = "#{self.class.name}\##{action_name} is missing a template " \ "for this request format and variant.\n" \ |