diff --git a/src/Fireable.php b/src/Fireable.php index 3930af4e9e51b1600f532fd1f91f1a29ca8f7a79..a91c0632e84d43fad1cd70719136cc14218f2062 100755 --- a/src/Fireable.php +++ b/src/Fireable.php @@ -10,16 +10,18 @@ class Fireable public function __construct( protected readonly Model $model, protected readonly array $fireableAttributes = [], - ) {} + ) { + } /** - * @param \BinaryCats\FireableAttributeEvents\FireableAttributes|Model $model + * @param \BinaryCats\FireableAttributeEvents\FireableAttributes|Model $model + * * @return $this */ public static function make(Model $model): static { return app(static::class, [ - 'model' => $model, + 'model' => $model, 'fireableAttributes' => $model->getFireableAttributes(), ]); } @@ -27,7 +29,7 @@ class Fireable /** * Match updated attributes with fireable ones and trigger events. * - * @param \BinaryCats\FireableAttributeEvents\FireableAttributes|Model $model + * @param \BinaryCats\FireableAttributeEvents\FireableAttributes|Model $model */ public function processAttributes(): void { diff --git a/tests/stubs/StatusChangedToOpen.php b/tests/stubs/StatusChangedToOpen.php index 5c650fc66f43326be4d6c25404c99a3904772285..057b78e891d59dd2e027c3115ba8f49cda576e61 100644 --- a/tests/stubs/StatusChangedToOpen.php +++ b/tests/stubs/StatusChangedToOpen.php @@ -6,5 +6,6 @@ class StatusChangedToOpen { public function __construct( public readonly TestModel $model, - ) {} + ) { + } } diff --git a/tests/stubs/TestModel.php b/tests/stubs/TestModel.php index 1e4c2790f5b16783ead7d04893c4bc23285d73d2..7aee2b3feeb23e2c0a47eed71d90bc8277604eb4 100644 --- a/tests/stubs/TestModel.php +++ b/tests/stubs/TestModel.php @@ -13,7 +13,7 @@ class TestModel extends Model protected $guarded = []; protected array $fireableAttributes = [ - 'value' => ValueChanged::class, + 'value' => ValueChanged::class, 'status' => [ 'open' => StatusChangedToOpen::class, ], diff --git a/tests/stubs/ValueChanged.php b/tests/stubs/ValueChanged.php index 346c497fefde9ca248ff93e7172b069f87dd1bc6..17397af794a0a1ab30d071541afc1c8405ee0f6d 100644 --- a/tests/stubs/ValueChanged.php +++ b/tests/stubs/ValueChanged.php @@ -6,5 +6,6 @@ class ValueChanged { public function __construct( public readonly TestModel $model, - ) {} + ) { + } }