diff --git a/PHP/src/A/Money.php b/PHP/src/A/Money.php index 3cb8810..c055909 100644 --- a/PHP/src/A/Money.php +++ b/PHP/src/A/Money.php @@ -32,8 +32,4 @@ public function reduceBy(int $p): Money { public function moreThan(Money $other): bool { return $this->value->compareTo($other->value) > 0; } - - public function __equals($other): bool { - return $this->value->isEqualTo($other->value); - } } diff --git a/PHP/src/C/Money.php b/PHP/src/C/Money.php index 691ca58..1be02cb 100644 --- a/PHP/src/C/Money.php +++ b/PHP/src/C/Money.php @@ -26,16 +26,10 @@ public function percentage(int $p): Money { } public function format(): String { - return number_format($value->toFloat(), 2, '.', ''); - } - - public function __equals($other): bool { - return $this->value->isEqualTo($other->value); + return number_format($this->value->toFloat(), 2, '.', ''); } public function asBigDecimal(): BigDecimal { return $this->value; } - } - diff --git a/PHP/src/D/Money.php b/PHP/src/D/Money.php index f0c2838..87d2574 100644 --- a/PHP/src/D/Money.php +++ b/PHP/src/D/Money.php @@ -22,16 +22,10 @@ public function percentage(int $p): Money { } public function format(): String { - return number_format($value->toFloat(), 2, '.', ''); - } - - public function __equals($other): bool { - return $this->value->isEqualTo($other->value); + return number_format($this->value->toFloat(), 2, '.', ''); } public function asBigDecimal(): BigDecimal { return $this->value; } - } -