refactor view and content type