Re-implemented partial download from file.
Minor refactor.