OWASP/railsgoat — pull request #144 by jamesejr (2014-07-26 04:23:54+00:00)
Title: Fixes #142 with dynamic Action Mailer url options

Fixes #142. I spent some time reading about Action Mailer URL generation. I'm not sure if this is the best approach (maybe it's a bit hacky?), but if I understand the issue here, this seems to resolve it. When I implemented this feature, I had to pass the `:host` parameter to `url_for`. Instead, I ended up defining `localhost:3000` in the development environment configuration.

My thought here as a possible solution is to generate the host value without defining it as a specific default. Thoughts?

**References:**
http://simonecarletti.com/blog/2009/10/actionmailer-and-host-value/
http://guides.rubyonrails.org/action_mailer_basics.html#generating-urls-in-action-mailer-views