Module: ActiveRecord

Defined in:
lib/validates_as_email.rb

Overview

Validation helper for ActiveRecord derived objects that cleanly and simply allows the model to check if the given string is a syntactically valid email address (by using the RFC822 module above).

Original code by Ximon Eighteen <[email protected]> which was heavily based on code I can no longer find on the net, my apologies to the author!

Huge credit goes to Dan Kubb <[email protected]> for submitting a patch to massively simplify this code and thereby instruct me in the ways of Rails too! I reflowed the patch a little to keep the line length to a maximum of 78 characters, an old habit.

Defined Under Namespace

Modules: Validations