Rails 3 Action Mailer uninitialized constant
问题 I'm trying to use actionmailer to notify me when a new comment has been posted but I keep getting the error: uninitialized constant CommentsController::CommentMailer The comment is added to my database and can be viewed. I am also using devise and it's email functions are working fine. My comment mailer: class CommentMailer < ActionMailer::Base def newcomment(comment) mail(:to => "admin@example.com", :subject => "New Comment") end end and my controller section: def create @comment = Comment