More fixes for profiles and entities.