Skip to content

Commit

Permalink
Destroy event session RSVPs when event sessions are destroyed
Browse files Browse the repository at this point in the history
  • Loading branch information
tjgrathwell committed Mar 25, 2013
1 parent a6b4c0a commit bf31288
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/event_session.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class EventSession < ActiveRecord::Base
validates_uniqueness_of :name, scope: [:event_id]

belongs_to :event
has_many :rsvp_sessions
has_many :rsvp_sessions, dependent: :destroy
has_many :rsvps, :through => :rsvp_sessions

def session_date
Expand Down

0 comments on commit bf31288

Please sign in to comment.