Skip to content

Commit

Permalink
Don't inadvertently hit const_missing in defined?(ActionMailer::Base)…
Browse files Browse the repository at this point in the history
… check

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8249 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information
jeremy committed Dec 1, 2007
1 parent e47392b commit 2a3dc59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion actionpack/lib/action_view/base.rb
Expand Up @@ -276,7 +276,7 @@ def initialize(view_paths = [], assigns_for_first_render = {}, controller = nil)
# it's relative to the view_paths array, otherwise it's absolute. The hash in <tt>local_assigns</tt>
# is made available as local variables.
def render_file(template_path, use_full_path = true, local_assigns = {}) #:nodoc:
if defined?(ActionMailer::Base) && controller.is_a?(ActionMailer::Base) && !template_path.include?("/")
if defined?(ActionMailer) && controller.is_a?(ActionMailer::Base) && !template_path.include?("/")
raise ActionViewError, <<-END_ERROR
Due to changes in ActionMailer, you need to provide the mailer_name along with the template name.
Expand Down

0 comments on commit 2a3dc59

Please sign in to comment.