fix authentication model