save downloaded files and restore it while loading