From e3800e4a24737ba0ca58b8196fda0e3a94ff29d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20B=C3=B6hmer?= Date: Sun, 29 Mar 2020 23:54:14 +0200 Subject: [PATCH] Fixed exception. --- src/Services/AmountFormatter.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Services/AmountFormatter.php b/src/Services/AmountFormatter.php index 7a2f3c5b..c679e035 100644 --- a/src/Services/AmountFormatter.php +++ b/src/Services/AmountFormatter.php @@ -62,17 +62,15 @@ class AmountFormatter /** * Formats the given value using the measurement unit and options. * + * @param float|string|int $value * @param MeasurementUnit|null $unit The measurement unit, whose unit symbol should be used for formatting. * If set to null, it is assumed that the part amount is measured in pieces. * - * @param MeasurementUnit|null $unit The measurement unit, whose unit symbol should be used for formatting. - * If set to null, it is assumed that the part amount is measured in pieces. - * * @return string The formatted string * * @throws InvalidArgumentException thrown if $value is not numeric */ - public function format(float $value, ?MeasurementUnit $unit = null, array $options = []) + public function format($value, ?MeasurementUnit $unit = null, array $options = []) { if (! is_numeric($value)) { throw new InvalidArgumentException('$value must be an numeric value!');