1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actionpack/lib/action_controller/metal/implicit_render.rb
Carlos Antonio da Silva 1b4edd173d Use performed? instead of checking for response_body
* Check for performed? instead of response_body
* Change performed? to return a boolean
* Refactor AC::Metal#response_body= to reuse variable
2012-01-19 18:25:52 -02:00

19 lines
374 B
Ruby

module ActionController
module ImplicitRender
def send_action(method, *args)
ret = super
default_render unless performed?
ret
end
def default_render(*args)
render(*args)
end
def method_for_action(action_name)
super || if template_exists?(action_name.to_s, _prefixes)
"default_render"
end
end
end
end