Fix same file content = same hash
This commit is contained in:
parent
f682edb4f2
commit
d1cd43c9d8
@ -1783,7 +1783,7 @@ class CMailFile
|
|||||||
foreach ($matches[1] as $key => $ext) {
|
foreach ($matches[1] as $key => $ext) {
|
||||||
// We save the image to send in disk
|
// We save the image to send in disk
|
||||||
$filecontent = $matches[2][$key];
|
$filecontent = $matches[2][$key];
|
||||||
$cid = dol_hash(uniqid(time()), 3);
|
$cid = dol_hash($this->html, 'md5');
|
||||||
$destfiletmp = $images_dir.'/'.$cid.'.'.$ext;
|
$destfiletmp = $images_dir.'/'.$cid.'.'.$ext;
|
||||||
|
|
||||||
$fhandle = @fopen($destfiletmp, 'w');
|
$fhandle = @fopen($destfiletmp, 'w');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user