I was wondering how I’m suppose to associate my User, Post, and Comment models. It is suppose to be like so: The user can comment on any post and a post belongs to a user with a Boolean for being admin. I have been scratching my had for awhile trying to figure this out but nothing has made any sense at all.
Any help would be greatly appreciated.
In the most obvious arrangement
Postwouldbelong_to :userandhas_many :comments, andCommentwould bothbelong_to :userandbelong_to :post.Userwouldhas_many :posts.