Refactor utils #5.