Skip to content

Commit e429a02

Browse files
lrljoegithub-actions[bot]
authored andcommitted
Fix styling
1 parent 2d0eded commit e429a02

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

src/Traits/Filters/HandlesPillsData.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ public function getPillDataForFilter(): array
1111
$filters = [];
1212

1313
foreach ($this->getAppliedFiltersWithValuesForPills() as $filterKey => $value) {
14-
if (! is_null($filter = $this->getFilterByKey($filterKey)) && !$filter->isEmpty($filter->validate($value))) {
14+
if (! is_null($filter = $this->getFilterByKey($filterKey)) && ! $filter->isEmpty($filter->validate($value))) {
1515
$filters[$filter->getKey()] = FilterPillData::make(
1616
filterKey: $filter->getKey(),
1717
customPillBlade: $filter->getCustomPillBlade() ?? null,

src/Views/Filters/DateRangeFilter.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -198,8 +198,7 @@ public function getFilterPillValue($value): array|string|bool|null
198198

199199
public function isEmpty(array|string|null $value): bool
200200
{
201-
if(is_null($value) || empty($value))
202-
{
201+
if (is_null($value) || empty($value)) {
203202
return true;
204203
}
205204
$values = [];

tests/Unit/Views/Filters/DateRangeFilterTest.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -438,9 +438,9 @@ public function test_check_if_can_get_locale(): void
438438

439439
public function test_can_check_validation_rejects_invalid_values_array(): void
440440
{
441-
$missingStartDate = self::$filterInstance->validate([null,'2020-01-01']);
441+
$missingStartDate = self::$filterInstance->validate([null, '2020-01-01']);
442442
$missingEndDate = self::$filterInstance->validate(['2020-01-01', null]);
443-
$missingBoth = self::$filterInstance->validate([null,null]);
443+
$missingBoth = self::$filterInstance->validate([null, null]);
444444

445445
$this->assertFalse($missingStartDate);
446446
$this->assertFalse($missingEndDate);
@@ -454,6 +454,4 @@ public function test_can_check_validation_rejects_broken_values_array(): void
454454
{
455455
$this->assertFalse(self::$filterInstance->validate(['minDate' => 'asdf', 'maxDate' => '2020-02-02']));
456456
}
457-
458-
459457
}

0 commit comments

Comments
 (0)