mirror of
https://github.com/corpnewt/gibMacOS.git
synced 2024-12-04 13:33:26 +01:00
Verify download result before assuming success
This commit is contained in:
parent
db60668857
commit
f4d09d4157
@ -346,7 +346,8 @@ class gibMacOS:
|
||||
self.u.info("NOTE: Only Downloading DMG Files\n")
|
||||
self.u.info("Downloading {} for {}...\n".format(os.path.basename(x), name))
|
||||
try:
|
||||
self.d.stream_to_file(x, os.path.join(download_dir, os.path.basename(x)))
|
||||
result = self.d.stream_to_file(x, os.path.join(download_dir, os.path.basename(x)))
|
||||
assert result is not None
|
||||
done.append({"name":os.path.basename(x), "status":True})
|
||||
except:
|
||||
done.append({"name":os.path.basename(x), "status":False})
|
||||
|
Loading…
Reference in New Issue
Block a user