Skip to content

[Form] Document null support in NumberToLocalizedStringTransformer #41453

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 3, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function __construct(?int $scale = 2, ?bool $grouping = true, ?int $round
/**
* Transforms a normalized format into a localized money string.
*
* @param int|float $value Normalized number
* @param int|float|null $value Normalized number
*
* @return string Localized money string
*
Expand All @@ -69,7 +69,7 @@ public function transform($value)
*
* @param string $value Localized money string
*
* @return int|float Normalized number
* @return int|float|null Normalized number
*
* @throws TransformationFailedException if the given value is not a string
* or if the value can not be transformed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public function __construct(int $scale = null, ?bool $grouping = false, ?int $ro
/**
* Transforms a number type into localized number.
*
* @param int|float $value Number value
* @param int|float|null $value Number value
*
* @return string Localized value
*
Expand Down Expand Up @@ -133,7 +133,7 @@ public function transform($value)
*
* @param string $value The localized value
*
* @return int|float The numeric value
* @return int|float|null The numeric value
*
* @throws TransformationFailedException if the given value is not a string
* or if the value can not be transformed
Expand Down