Are you thinking about newsletter situations?
Ususally when I send an email I already have the user object in my
hand (most of my emails are for things like watchlist changes,
questions from other users, etc.), so an if statement to check whether
the user wants to receive emails would be a lot cheaper than doing
another database query.
Well, if you have done a @user = User.find(123) then doing
@user.wants_email? shouldn't generate another DB query as it should
hit the ActiveRecord cache.
Why can't you just do:
deliver_email if @user.subscribed
and have a boolean value in your table called "subscribed"
I think that would be about as clean and dry as can be.
If you want to put it in your create_email method, you will have to
make a method in your Notifier that creates the email but checks the
users subscription status first....