fixed has_belongs_to_many problem