Skip to content

Commit

Permalink
Allow use float in serialized field
Browse files Browse the repository at this point in the history
  • Loading branch information
vtsykun committed Dec 22, 2023
1 parent 2f5ad26 commit 3a3a0f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Entity/SerializedFieldsTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ trait SerializedFieldsTrait
#[ORM\Column(name: 'serialized_fields', type: 'json', nullable: true)]
private ?array $serializedFields = null;

public function getSerialized(string $field, ?string $type = null, mixed $default = null): int|null|array|string|bool
public function getSerialized(string $field, ?string $type = null, mixed $default = null): int|null|array|string|bool|float
{
$value = $this->serializedFields[$field] ?? $default;
static $aliases = [
Expand Down

0 comments on commit 3a3a0f9

Please sign in to comment.