Explorar o código

:wrench: QRGdImage: fix "Implicit conversion from float to int" in PHP 8.1

smiley %!s(int64=3) %!d(string=hai) anos
pai
achega
66ac346c36
Modificáronse 1 ficheiros con 4 adicións e 4 borrados
  1. 4 4
      src/Output/QRGdImage.php

+ 4 - 4
src/Output/QRGdImage.php

@@ -150,10 +150,10 @@ class QRGdImage extends QROutputAbstract{
 		$this->options->drawCircularModules && $this->matrix->checkTypeNotIn($x, $y, $this->options->keepAsSquare)
 			? imagefilledellipse(
 				$this->image,
-				($x * $this->scale) + ($this->scale / 2),
-				($y * $this->scale) + ($this->scale / 2),
-				2 * $this->options->circleRadius * $this->scale,
-				2 * $this->options->circleRadius * $this->scale,
+				(int)(($x * $this->scale) + ($this->scale / 2)),
+				(int)(($y * $this->scale) + ($this->scale / 2)),
+				(int)(2 * $this->options->circleRadius * $this->scale),
+				(int)(2 * $this->options->circleRadius * $this->scale),
 				$color
 			)
 			: imagefilledrectangle(