From bd924ab21904e12e7c125ce5ee100772f2315167 Mon Sep 17 00:00:00 2001 From: Sebastian Martinez Date: Thu, 4 Aug 2011 16:12:04 -0300 Subject: [PATCH] Fix custom section partials not being found in view path. --- lib/exception_notifier/notifier.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/exception_notifier/notifier.rb b/lib/exception_notifier/notifier.rb index a5d029d1..eb11b5f2 100644 --- a/lib/exception_notifier/notifier.rb +++ b/lib/exception_notifier/notifier.rb @@ -4,6 +4,8 @@ class ExceptionNotifier class Notifier < ActionMailer::Base self.mailer_name = 'exception_notifier' + #Append application view path to the ExceptionNotifier lookup context. + self.append_view_path Rails.root.nil? ? "app/views" : "#{Rails.root}/app/views" if defined?(Rails) self.append_view_path "#{File.dirname(__FILE__)}/views" class << self