diff options
Diffstat (limited to 'app/models/blog_post.rb')
-rw-r--r-- | app/models/blog_post.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/blog_post.rb b/app/models/blog_post.rb index f2a1465..ccd10e2 100644 --- a/app/models/blog_post.rb +++ b/app/models/blog_post.rb @@ -1,6 +1,6 @@ class BlogPost < ActiveRecord::Base - has_many :comments, :class_name => 'BlogComment' + has_many :comments, :class_name => 'BlogComment', :dependent => :destroy has_and_belongs_to_many :categories, :class_name => 'BlogCategory' acts_as_indexed :fields => [:title, :body] |