Skip to content

Instantly share code, notes, and snippets.

@mynameisrufus
Created December 15, 2010 06:37
Show Gist options
  • Save mynameisrufus/741699 to your computer and use it in GitHub Desktop.
Save mynameisrufus/741699 to your computer and use it in GitHub Desktop.
after_save :remove_erroneous_record
def remove_erroneous_record
self.destroy if created_in_error?
end
def created_in_error?
referral_outcome == "Created in Error"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment