Sha256: 154df0a7bb5c8be70a65faaf074002e43a2b8228c431b62a12ab609bd841e0e1
Contents?: true
Size: 907 Bytes
Versions: 14
Compression:
Stored size: 907 Bytes
Contents
module Dugway module Drops class ContactDrop < BaseDrop def name params[:name] ||= '' end def email params[:email] ||= '' end def subject params[:subject] ||= '' end def message params[:message] ||= '' end def captcha %{<img id="captcha_image" src="https://s3.amazonaws.com/bigcartel/captcha/28e3d1288cbc70c0cd1a2d10845f8e11e1a90d14.png">} end def recaptcha @recaptcha ||= begin html = "This site is protected by reCAPTCHA and the Google " html += '<a href="https://policies.google.com/privacy">Privacy Policy</a> and ' html += '<a href="https://policies.google.com/terms">Terms of Service</a> apply.' html end end def sent request.path == '/contact' && request.post? && errors.blank? end end end end
Version data entries
14 entries across 14 versions & 1 rubygems