1
0
Fork 0

Added a check for the return code when extracting zip file

pull/1010/head
Baldur Rensch 2012-08-17 13:06:58 -07:00
parent 7b3ce479cd
commit 1398757963
1 changed files with 4 additions and 1 deletions

View File

@ -54,7 +54,10 @@ class ZipDownloader extends ArchiveDownloader
throw new \UnexpectedValueException($this->getErrorMessage($retval, $file));
}
$zipArchive->extractTo($path);
if (true !== $zipArchive->extractTo($path)) {
throw new \RuntimeException("There was an error extracting the ZIP file. Corrupt file?");
}
$zipArchive->close();
}