Refactor some sample smell code.