diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2015-08-26 16:34:07 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2015-08-26 16:34:07 -0700 |
commit | e6425f6ecad2a1b771455f73ada9d15f72a687eb (patch) | |
tree | 321d0d6e77950be5a1450b00343c4a8067f76554 /actionpack/lib | |
parent | 446b6855dc88715315ce1ea15c25d1e821f8e598 (diff) | |
download | rails-e6425f6ecad2a1b771455f73ada9d15f72a687eb.tar.gz rails-e6425f6ecad2a1b771455f73ada9d15f72a687eb.tar.bz2 rails-e6425f6ecad2a1b771455f73ada9d15f72a687eb.zip |
Remove useless conditional
If the response method is defined, then calling `response` will return a
response.
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/abstract_controller/rendering.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/abstract_controller/rendering.rb b/actionpack/lib/abstract_controller/rendering.rb index 0a28c9aea1..2bb7c2139e 100644 --- a/actionpack/lib/abstract_controller/rendering.rb +++ b/actionpack/lib/abstract_controller/rendering.rb @@ -118,7 +118,7 @@ module AbstractController def _normalize_render(*args, &block) options = _normalize_args(*args, &block) #TODO: remove defined? when we restore AP <=> AV dependency - if defined?(request) && request && request.variant.present? + if defined?(request) && request.variant.present? options[:variant] = request.variant end _normalize_options(options) |