Ensure we are always saving the image height and width as ints
This commit is contained in:
parent
ed93542c0c
commit
e480f5c98f
1 changed files with 2 additions and 2 deletions
|
@ -120,8 +120,8 @@ class element extends \mod_customcert\element {
|
||||||
// Array of data we will be storing in the database.
|
// Array of data we will be storing in the database.
|
||||||
$arrtostore = array(
|
$arrtostore = array(
|
||||||
'pathnamehash' => $data->image,
|
'pathnamehash' => $data->image,
|
||||||
'width' => $data->width,
|
'width' => (int) $data->width,
|
||||||
'height' => $data->height
|
'height' => (int) $data->height
|
||||||
);
|
);
|
||||||
|
|
||||||
return json_encode($arrtostore);
|
return json_encode($arrtostore);
|
||||||
|
|
Loading…
Reference in a new issue