| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 25 | public function dbTypecast(mixed $value): mixed |
||
| 26 | { |
||
| 27 | return match (true) { |
||
| 28 | is_string($value), $value === null, is_resource($value), $value instanceof ExpressionInterface => $value, |
||
| 29 | /** ensure type cast always has . as decimal separator in all locales */ |
||
| 30 | is_float($value) => DbStringHelper::normalizeFloat($value), |
||
| 31 | $value === false => '0', |
||
| 32 | default => (string) $value, |
||
| 33 | }; |
||
| 36 |