fix the bug when downloading