Skip to content

Commit

Permalink
Fix deprecated warning
Browse files Browse the repository at this point in the history
  • Loading branch information
francoism90 committed Jun 21, 2024
1 parent d9c7fa2 commit 1744d66
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Support/Blade/Bladeable.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public static function classMerged(ComponentAttributeBag $attributeBag, ?array $
$values ??= static::classAttributes($attributeBag);

return collect($values)
->map(function (mixed $value = null, int|string $key) use ($attributeBag) {
->map(function (mixed $value, int|string $key) use ($attributeBag) {
if (is_bool($value) && $value === false) {
return;
}
Expand All @@ -27,7 +27,8 @@ public static function classMerged(ComponentAttributeBag $attributeBag, ?array $

public static function classAttributes(ComponentAttributeBag $attributeBag): Collection
{
return str($attributeBag->whereStartsWith('class:'))->matchAll('/class:(.*?)\=/s');
return str($attributeBag->whereStartsWith('class:'))
->matchAll('/class:(.*?)\=/s');
}

public static function classKeys(...$keys): Collection
Expand Down

0 comments on commit 1744d66

Please sign in to comment.