Class: Draft

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
app/models/draft.rb

Instance Method Summary collapse

Instance Method Details

#before_saveObject



7
8
9
10
11
# File 'app/models/draft.rb', line 7

def before_save
  self.subject = CGI.escapeElement(self.subject, 'script') if self.subject
  self.tb_url  = CGI.escapeElement(self.tb_url, 'script')  if self.tb_url
  self.body    = CGI.escapeElement(self.body, 'script')    if self.body
end