Corrected thumbnail creation.
Because some systems do not allow file overwriting when doing a rename().
This commit is contained in:
parent
ab7ac1870e
commit
9e8209064d
1 changed files with 1 additions and 0 deletions
|
@ -2336,6 +2336,7 @@ function resizeImage($filepath)
|
|||
imagejpeg($im2, $tempname, 90);
|
||||
imagedestroy($im);
|
||||
imagedestroy($im2);
|
||||
unlink($filepath);
|
||||
rename($tempname,$filepath); // Overwrite original picture with thumbnail.
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue