Merge pull request #145 from woytam/patch-1

Problem with $imagekeys undefined or unlinked
This commit is contained in:
Nicola Asuni 2020-02-12 11:18:46 +00:00 committed by GitHub
commit fe779adc9e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7785,10 +7785,8 @@ class TCPDF {
}
closedir($handle);
}
if (isset($this->imagekeys)) {
foreach($this->imagekeys as $file) {
if(substr($file, 0 , strlen(K_PATH_CACHE)) === K_PATH_CACHE && is_file($file)) unlink($file);
}
foreach($this->imagekeys as $file) {
unlink($file);
}
}
$preserve = array(
@ -7798,6 +7796,7 @@ class TCPDF {
'bufferlen',
'buffer',
'cached_files',
'imagekeys',
'sign',
'signature_data',
'signature_max_length',