(cp 732145f6b) fixes #2484 force integer on width/height

... was string when original url was used as derivative url (when the original is smaller than the derivative dimensions)
This commit is contained in:
plegall
2025-12-22 11:46:49 +01:00
parent 6858acda37
commit 637db278fb

View File

@@ -168,7 +168,7 @@ function ws_std_get_urls($image_row)
{
$size = $derivative->get_size();
$size != null or $size=array(null,null);
$derivatives_arr[$type] = array('url' => $derivative->get_url(), 'width'=>$size[0], 'height'=>$size[1] );
$derivatives_arr[$type] = array('url' => $derivative->get_url(), 'width'=>(int)$size[0], 'height'=>(int)$size[1] );
}
$ret['derivatives'] = $derivatives_arr;;
return $ret;