blob: 7c88c510cb6d219da846ec1f1c2dd8d90b151140 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
class Email
include CouchRest::Model::Embeddable
property :email, String
validates :email_forward,
:format => { :with => /\A([^@\s]+)@((?:[-a-z0-9]+\.)+[a-z]{2,})\Z/, :message => "needs to be a valid email address"}
timestamps!
def to_s
email
end
end
|