Added download-modes function.