mirror of
https://github.com/dg/dibi.git
synced 2025-08-06 22:26:43 +02:00
Result: improved normalization of int
This commit is contained in:
@@ -492,7 +492,9 @@ class DibiResult extends DibiObject implements IDataSource
|
||||
if ($value === FALSE || $type === dibi::TEXT) {
|
||||
|
||||
} elseif ($type === dibi::INTEGER) {
|
||||
$row[$key] = is_float($tmp = $value * 1) ? $value : $tmp;
|
||||
$row[$key] = is_float($tmp = $value * 1)
|
||||
? (is_string($value) ? $value : (int) $value)
|
||||
: $tmp;
|
||||
|
||||
} elseif ($type === dibi::FLOAT) {
|
||||
$value = ltrim($value, '0');
|
||||
|
Reference in New Issue
Block a user