fixed bug in belongs_to