Trevor Turk

A chess-playing machine of the late 18th century, promoted as an automaton but later proved a hoax.

Logging outgoing emails in Rails 3

Let's say you want to have a log of all outgoing emails in your Rails 3 app. Thanks to some pretty sweet notification support in the Mail gem, it's really simple. Here's an example using Mongoid: Initially, I was logging the entire contents of the email, but that included attachments as well. So, now I'm just logging the body. I wonder if there's a better choice of what to log, though... Any ideas?

« Home page