refactor download stat