Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
pelmered committed Dec 5, 2024
1 parent 1bd7cc7 commit 6fc5346
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Infolists/Components/MoneyEntry.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public function short(): static

public function hideCurrencySymbol(bool $hideCurrencySymbol = true): static
{
$this->showCurrencySymbol = !$hideCurrencySymbol;
$this->showCurrencySymbol = ! $hideCurrencySymbol;

return $this;

Check notice on line 51 in src/Infolists/Components/MoneyEntry.php

View check run for this annotation

OtterWise Otto / Code Coverage

src/Infolists/Components/MoneyEntry.php:49

Lines 49 - 51 are not covered by tests.
}
Expand Down
2 changes: 2 additions & 0 deletions src/MoneyFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,10 @@ public static function formatShort(
if ($value < 100000) {
if (! $showCurrencySymbol) {
dump($value);

return static::numberFormat((int) $value / 100, $currency, $locale, decimals: $decimals);
}

return static::format($value, $currency, $locale, $decimals);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Tables/Columns/MoneyColumn.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public function short(): static

public function hideCurrencySymbol(bool $hideCurrencySymbol = true): static
{
$this->showCurrencySymbol = !$hideCurrencySymbol;
$this->showCurrencySymbol = ! $hideCurrencySymbol;

return $this;
}
Expand Down
1 change: 0 additions & 1 deletion tests/MoneyColumnTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,3 @@
expect($column->formatState(23523562))->toEqual(replaceNonBreakingSpaces('235,24K'));
expect($column->formatState(2352356254))->toEqual(replaceNonBreakingSpaces('23,52M'));
});

0 comments on commit 6fc5346

Please sign in to comment.