refactor user detail