:octocat: PHP 8.5 deprecation: imagedestroy()

This commit is contained in:
smiley
2025-10-29 19:36:43 +01:00
parent b1efebb7c2
commit bc7ba5e22a
2 changed files with 1 additions and 3 deletions
-1
View File
@@ -75,7 +75,6 @@ class QRImageWithText extends QRGdImagePNG{
// copy over the qrcode
imagecopymerge($this->image, $qrcode, 0, 0, 0, 0, $this->length, $this->length, 100);
imagedestroy($qrcode);
$fontColor = imagecolorallocate($this->image, ...$textColor);
$w = imagefontwidth($textSize);
+1 -2
View File
@@ -17,7 +17,7 @@ use chillerlan\Settings\SettingsContainerInterface;
use ErrorException;
use Throwable;
use function array_values, count, extension_loaded, imagebmp, imagecolorallocate, imagecolortransparent,
imagecreatetruecolor, imagedestroy, imagefilledellipse, imagefilledrectangle, imagegif, imagejpeg, imagepng,
imagecreatetruecolor, imagefilledellipse, imagefilledrectangle, imagegif, imagejpeg, imagepng,
imagescale, imagetypes, imagewebp, intdiv, intval, is_array, is_numeric, max, min, ob_end_clean, ob_get_contents, ob_start,
restore_error_handler, set_error_handler, sprintf;
use const IMG_BMP, IMG_GIF, IMG_JPG, IMG_PNG, IMG_WEBP;
@@ -378,7 +378,6 @@ class QRGdImage extends QROutputAbstract{
$this->renderImage();
$imageData = ob_get_contents();
imagedestroy($this->image);
}
// not going to cover edge cases
// @codeCoverageIgnoreStart