diff options
author | Yehuda Katz <wycats@gmail.com> | 2009-08-07 15:00:12 -0300 |
---|---|---|
committer | Yehuda Katz <wycats@gmail.com> | 2009-08-07 15:00:12 -0300 |
commit | 010a0c92eb573cd4c216c51371356adddfde11cf (patch) | |
tree | 96da751eaf21bcac20818440657b3f38a6687ffc /actionpack/lib/action_controller | |
parent | 55575e21655023259d0dae22bc1b148b34168d92 (diff) | |
download | rails-010a0c92eb573cd4c216c51371356adddfde11cf.tar.gz rails-010a0c92eb573cd4c216c51371356adddfde11cf.tar.bz2 rails-010a0c92eb573cd4c216c51371356adddfde11cf.zip |
Rename find_by_parts and find_by_parts? to find and exists?
Diffstat (limited to 'actionpack/lib/action_controller')
-rw-r--r-- | actionpack/lib/action_controller/base.rb | 2 | ||||
-rw-r--r-- | actionpack/lib/action_controller/legacy/layout.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index 40f4802b74..61f1c715c8 100644 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -51,7 +51,7 @@ module ActionController def method_for_action(action_name) super || begin - if view_paths.find_by_parts?(action_name.to_s, {:formats => formats, :locales => [I18n.locale]}, controller_path) + if view_paths.exists?(action_name.to_s, {:formats => formats, :locales => [I18n.locale]}, controller_path) "default_render" end end diff --git a/actionpack/lib/action_controller/legacy/layout.rb b/actionpack/lib/action_controller/legacy/layout.rb index 3f3d20b95f..43aea0eba2 100644 --- a/actionpack/lib/action_controller/legacy/layout.rb +++ b/actionpack/lib/action_controller/legacy/layout.rb @@ -191,7 +191,7 @@ module ActionController #:nodoc: def memoized_find_layout(layout, formats) #:nodoc: return layout if layout.nil? || layout.respond_to?(:render) prefix = layout.to_s =~ /layouts\// ? nil : "layouts" - view_paths.find_by_parts(layout.to_s, {:formats => formats}, prefix) + view_paths.find(layout.to_s, {:formats => formats}, prefix) end def find_layout(*args) |