Cache $todoList and improve readability