ActionMailer Confusion

I am running Rails 2.3.2.

I had something like the following in my environment.rb file:

ActionMailer::Base.delivery_method=:smtp ActionMailer::Base.server_settings={ :whatever }

Strangely, everything seemed to work just fine. Then Rails started complaining about my environment. Specifically, it complained that ActionMailer::Base did not have a server_settings method. A little Googling revealed that apparently things had gotten changed and that now I was supposed to use:

config.action_mailer.delivery_method = :smtp config.action_mailer.smtp_settings = { :whatever }

Now I'm getting complaints that there is no local variable or method, 'config'.

Can someone please tell me how to correctly make this configuration in my version of Rails? As I say, I have no idea how it ever worked. If anyone has any thoughts on that, I'd love to hear them as well. TIA.

            ... doug

I got this issue resolved and I thought I would mention what the solution was in case someone else encounters this situation. In retrospect, it was a rather stupid error on my part. When I appended the following 2 lines to my environment.rb file:

config.action_mailer.delivery_method = :smtp config.action_mailer.smtp_settings = { :whatever }

I did just that, I appended them. They should rather be INSERTED before the concluding 'end'. Sorry for the noise on this issue.

           ... doug