more minot php8 warning fixes

This commit is contained in:
Chris
2023-10-15 20:30:12 +02:00
parent a1bc5b5fa5
commit cea501d854

View File

@@ -91,14 +91,14 @@ function rotate(&$im,$direction)
if ($height > $width)
{
$ratio = $maxheight / $height;
$newheight = $maxheight;
$newwidth = $width * $ratio;
$newheight = intval($maxheight);
$newwidth = intval($width * $ratio) ;
}
else
{
$ratio = $maxwidth / $width;
$newwidth = $maxwidth;
$newheight = $height * $ratio;
$newwidth = intval($maxwidth) ;
$newheight = intval($height * $ratio);
}
$newimg = imagecreatetruecolor($newwidth,$newheight);