Inserted the has_and_belongs_to_many relation on models.