Found an issue that i don't know if it's the intended behaviour of the library. On the Medoo->dataMap() function, using the [Bool] dataType to auto convert the tinyint to bool php type, if i have that column on the database accepting null, the line:
$stack[ $column_key ] = (bool) $data[ $column_key ];
will convert null to false.
Is this your desired intent or is it possible to change that bool handling to handle null?
$stack[ $column_key ] = (is_null($data[ $column_key ])) ? null : (bool) $data[ $column_key ];
Hi there,
Found an issue that i don't know if it's the intended behaviour of the library. On the
Medoo->dataMap()
function, using the[Bool]
dataType to auto convert the tinyint to bool php type, if i have that column on the database accepting null, the line:$stack[ $column_key ] = (bool) $data[ $column_key ];
will convert null to false. Is this your desired intent or is it possible to change that bool handling to handle null?$stack[ $column_key ] = (is_null($data[ $column_key ])) ? null : (bool) $data[ $column_key ];
Thanks