Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardogobbosouza committed Mar 16, 2024
1 parent 9995c9b commit 0676585
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/Money.php
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ public function __call($method, array $arguments)
return $this->macroCall($method, $arguments);
}

if (!method_exists($this->money, $method)) {
if (! method_exists($this->money, $method)) {
throw new BadMethodCallException(sprintf(
'Call to undefined method %s::%s()',
static::class,
Expand All @@ -217,7 +217,7 @@ public function __call($method, array $arguments)
'absolute', 'negative',
];

if (!in_array($method, $methods)) {
if (! in_array($method, $methods)) {
return $result;
}

Expand Down Expand Up @@ -275,7 +275,7 @@ private static function getArguments(array $arguments = [])
*/
private static function convertResult($result)
{
if (!is_array($result)) {
if (! is_array($result)) {
return static::convert($result);
}

Expand Down Expand Up @@ -312,7 +312,7 @@ private static function resolveCalculator()
];

foreach ($calculators as $calculator) {
if (!class_exists($calculator)) {
if (! class_exists($calculator)) {
continue;
}

Expand Down
2 changes: 1 addition & 1 deletion tests/MoneyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ public function testAllocateTo()
public function testCallUndefinedMethod()
{
$this->expectException(BadMethodCallException::class);
$this->expectExceptionMessage('Call to undefined method ' . Money::class . '::undefined()');
$this->expectExceptionMessage('Call to undefined method '.Money::class.'::undefined()');

Money::USD(15)->undefined();
}
Expand Down

0 comments on commit 0676585

Please sign in to comment.