Class: BigBrotha::TabooPost
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- BigBrotha::TabooPost
- Defined in:
- lib/bigbrotha/models/taboo_post.rb
Instance Method Summary collapse
Instance Method Details
#set_taboos(new_taboos) ⇒ Object
17 18 19 20 21 22 23 24 25 |
# File 'lib/bigbrotha/models/taboo_post.rb', line 17 def set_taboos(new_taboos) taboos = [] new_taboos.try(:each) do |taboo| up = TabooPostsTaboo.new(taboo_post: self, taboo: taboo) taboos << up end TabooPostsTaboo.import taboos self.reload end |