Sha256: 83372d74024d1ea5141388958f649c7da5ef854c12ab4ba9b478aa9a2e0882b7
Contents?: true
Size: 456 Bytes
Versions: 6
Compression:
Stored size: 456 Bytes
Contents
module Wafflemix class ContactForm < ActiveRecord::Base attr_accessible :email, :message, :name, :subject validates_presence_of :email, :name include Spamster::Model spamster_attrs comment_author: :name, comment_author_email: :email after_create :check_for_spam def check_for_spam if ENV['AKISMET_SITE_URL'] && ENV['AKISMET_API_KEY'] self.spam = self.spamster.spam? self.save end end end end
Version data entries
6 entries across 6 versions & 1 rubygems