Refactor post /todos/:id/edit route on main.rb file.