Refactor double