summaryrefslogtreecommitdiff
path: root/help/app/models/account_extension/tickets.rb
blob: f898b56512ad850cc4676114f6effb515c83ac20 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
module AccountExtension::Tickets
  extend ActiveSupport::Concern

  def destroy_with_tickets
    Ticket.destroy_all_from(self.user)
    destroy_without_tickets
  end

  included do
    alias_method_chain :destroy, :tickets
  end

end