diff --git a/src/Fetchable.php b/src/Fetchable.php index aee8cf1..5ea58ab 100644 --- a/src/Fetchable.php +++ b/src/Fetchable.php @@ -144,6 +144,10 @@ protected function castRow( $key = key($assocArray); $value = $assocArray[$key]; + if($type === Type::DATETIME && is_numeric($value)) { + $value = "@$value"; + } + return match ($type) { Type::BOOL, "boolean" => (bool)$value, Type::INT, "integer" => (int)$value,