From 017ad8bbbaf8b1eefc3d6d13eb083735e555836a Mon Sep 17 00:00:00 2001 From: Adrien Leloup Date: Fri, 14 Jan 2022 15:51:52 +0100 Subject: [PATCH] Fixed return type doc --- src/Price.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Price.php b/src/Price.php index 36e029e..39af6e1 100644 --- a/src/Price.php +++ b/src/Price.php @@ -202,7 +202,7 @@ public function perUnit(Money $amount) $parts = floor($this->units); $remainder = $amount->multipliedBy($this->units - $parts, RoundingMode::FLOOR); - + $allocated = $amount->minus($remainder); return Money::min(...$allocated->split($parts)); @@ -239,7 +239,7 @@ public function invalidate() * Launch the total price calculator only if * it does not yet exist or has been invalidated. * - * @return void + * @return \Whitecube\Price\Calculator */ public function build() { @@ -253,7 +253,7 @@ public function build() } /** - * Convert this price object into a readable + * Convert this price object into a readable * total & inclusive money string * * @return string @@ -303,8 +303,8 @@ public static function json($value) } $base = Money::ofMinor($value['base'], $value['currency']); - + return (new static($base, $value['units'])) ->setVat($value['vat']); } -} \ No newline at end of file +}