Refactor a todo list