I have a rails app with articles and author model. If I have an author and a post and want to indicate that the author should be the owner of the article, or that the articl
I'm assuming you mean author_one.articles << my_article
rather than just author_one << my_article
One difference between the two is that
author_one.articles << my_article
will save the change to the database immediately. i.e. it will either create the record for my_article
if it has not been saved before or it will update the existing record to have author_id
= author_one.id
whereas
my_article.author = author_one
or
my_article.author_id = author_one.id
will not be persisted until you do a my_article.save