Skip to content

Instantly share code, notes, and snippets.

@chriscarter90
Created September 4, 2012 13:22
Show Gist options
  • Save chriscarter90/3621110 to your computer and use it in GitHub Desktop.
Save chriscarter90/3621110 to your computer and use it in GitHub Desktop.
class AbuseEmail
include Rails.application.routes.url_helpers
def default_url_options
{ :host => 'www.example.com' }
end
def self.to
"abuse@kweekweek.com"
end
def self.subject
"Reported Comment"
end
def self.body(comment)
<<-BODY
An abusive comment has been reported at the following address:
#{activity_url(comment.activity)}
The comment contains the following message:
"#{comment.body}"
BODY
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment