Paulo Bomfim

Joined

5,010 Experience
50 Lessons Completed
0 Questions Solved

Activity

Posted in Rails for Beginners Part 33: Twitter API Discussion

@Adalberto, @Konstantinos Gallis awnser your question in another video. Just do:

Checkout the video 39 (https://gorails.com/episodes/rails-for-beginners-part-39-dependent-destroy-model-associations)

Go in the file twitter_account.rb and replace:
has_many :tweets

with:
has_many :tweets, dependent: :destroy