aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2013-11-14 03:01:47 -0800
committerXavier Noria <fxn@hashref.com>2013-11-14 03:01:47 -0800
commit05427671d5c9a68d5b8cf883e246beb190e56c6f (patch)
tree64258e603ce7d800524eb561f8fb278bd3173ecd /actionpack/lib
parent436a9c1b85ffccf8ab3cbe6171a9196fa9e08476 (diff)
parent1529e610362739f793eae9474183fd2f301425ac (diff)
downloadrails-05427671d5c9a68d5b8cf883e246beb190e56c6f.tar.gz
rails-05427671d5c9a68d5b8cf883e246beb190e56c6f.tar.bz2
rails-05427671d5c9a68d5b8cf883e246beb190e56c6f.zip
Merge pull request #12886 from akshay-vishnoi/refactor
#presence used
Diffstat (limited to 'actionpack/lib')
-rw-r--r--actionpack/lib/action_controller/metal/rendering.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/actionpack/lib/action_controller/metal/rendering.rb b/actionpack/lib/action_controller/metal/rendering.rb
index 90f0ef0b1c..5c48b4ab98 100644
--- a/actionpack/lib/action_controller/metal/rendering.rb
+++ b/actionpack/lib/action_controller/metal/rendering.rb
@@ -27,11 +27,7 @@ module ActionController
end
def render_to_body(options = {})
- super || if options[:text].present?
- options[:text]
- else
- " "
- end
+ super || options[:text].presence || ' '
end
private