Actionmailer - TypeError: can't dup NilClass


#1

i am currently writing a mailer, and running into several problems
that i have not run into before…

suddenly, rails is asking me for the following:

ActionView::ActionViewError (Due to changes in ActionMailer, you need to
provide the mailer_name along with the template name.

i have changed my my file model to look like this:

,----[ notifier ]
| class Notifier < ActionMailer::Base
| def files_expiring(user_id)
| recipients ‘removed_email_address@domain.invalid’
| bcc “removed_email_address@domain.invalid”
| from “removed_email_address@domain.invalid”
| subject “some subject”
| render :file => “notifier/expire_files”
| end
| end
`----

when i run this, everything seems to be okay, but i get the following
error:

,----[ error message ]
| >> Notifier.deliver_files_expiring(25)
| Notifier.deliver_files_expiring(25)
| TypeError: can’t dup NilClass
| from /Library/Ruby/Gems/1.8/gems/actionpack-2.0.2/lib/action_view/template_error.rb:11:in dup' | from /Library/Ruby/Gems/1.8/gems/actionpack-2.0.2/lib/action_view/template_error.rb:11:ininitialize’
| from /Library/Ruby/Gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:322:in new' | from /Library/Ruby/Gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:322:inrender_file’
| from /Library/Ruby/Gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:348:in render' | from /Library/Ruby/Gems/1.8/gems/actionmailer-2.0.2/lib/action_mailer/base.rb:502:inrender’
| from /Users/sergio/Sites/file_manager/app/models/notifier.rb:7:in files_expiring' | from /Library/Ruby/Gems/1.8/gems/actionmailer-2.0.2/lib/action_mailer/base.rb:410:insend
| from /Library/Ruby/Gems/1.8/gems/actionmailer-2.0.2/lib/action_mailer/base.rb:410:in create!' | from /Library/Ruby/Gems/1.8/gems/actionmailer-2.0.2/lib/action_mailer/base.rb:403:ininitialize’
| from /Library/Ruby/Gems/1.8/gems/actionmailer-2.0.2/lib/action_mailer/base.rb:352:in new' | from /Library/Ruby/Gems/1.8/gems/actionmailer-2.0.2/lib/action_mailer/base.rb:352:inmethod_missing’
| from (irb):41
`----

at this point, the view has only some text in it, no reference to any
variables…

any help would be greatly appreciated…

thanks!