Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Move render :nothing and :text => nil options to AC::Rendering

  • Loading branch information...
commit 6244d16eaf8eea9ce963f08dced60399b121a6dc 1 parent 562a12d
@carlosantoniodasilva carlosantoniodasilva authored
View
3  actionpack/lib/abstract_controller/rendering.rb
@@ -165,6 +165,9 @@ def _normalize_options(options)
options[:prefixes] ||= _prefixes
end
+ options[:text] = nil if options.delete(:nothing) == true
+ options[:text] = " " if options.key?(:text) && options[:text].nil?
+
options[:template] ||= (options[:action] || action_name).to_s
options
end
View
10 actionpack/lib/action_controller/metal/compatibility.rb
@@ -14,12 +14,6 @@ class << self
]
end
- def _normalize_options(options)
- options[:text] = nil if options.delete(:nothing) == true
- options[:text] = " " if options.key?(:text) && options[:text].nil?
- super
- end
-
def render_to_body(options)
super || " "
end
@@ -31,9 +25,5 @@ def _handle_method_missing
def method_for_action(action_name)
super || (respond_to?(:method_missing) && "_handle_method_missing")
end
-
- def performed?
- response_body
- end
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.