refactor some code, and change question display type