Fix error when downloading