Skip to content

Commit

Permalink
Fix styling
Browse files Browse the repository at this point in the history
  • Loading branch information
freekmurze authored and actions-user committed Jan 21, 2022
1 parent a3b10fe commit 64a3365
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/SortableTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public static function setNewOrder($ids, int $startOrder = 1, string $primaryKey
throw new InvalidArgumentException('You must pass an array or ArrayAccess object to setNewOrder');
}

$model = new static;
$model = new static();

$orderColumnName = $model->determineOrderColumnName();

Expand Down
10 changes: 5 additions & 5 deletions tests/SortableTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ public function it_will_determine_to_sort_when_creating_if_sortable_attribute_do
/** @test */
public function it_will_determine_to_sort_when_creating_if_sort_when_creating_setting_does_not_exist()
{
$model = new class extends Dummy {
$model = new class () extends Dummy {
public $sortable = [];
};

Expand All @@ -167,13 +167,13 @@ public function it_will_determine_to_sort_when_creating_if_sort_when_creating_se
/** @test */
public function it_will_respect_the_sort_when_creating_setting()
{
$model = new class extends Dummy {
$model = new class () extends Dummy {
public $sortable = ['sort_when_creating' => true];
};

$this->assertTrue($model->shouldSortWhenCreating());

$model = new class extends Dummy {
$model = new class () extends Dummy {
public $sortable = ['sort_when_creating' => false];
};
$this->assertFalse($model->shouldSortWhenCreating());
Expand Down Expand Up @@ -334,7 +334,7 @@ public function it_can_use_config_properties()
'eloquent-sortable.sort_when_creating' => true,
]);

$model = new class extends Dummy {
$model = new class () extends Dummy {
public $sortable = [];
};

Expand All @@ -345,7 +345,7 @@ public function it_can_use_config_properties()
/** @test */
public function it_can_override_config_properties()
{
$model = new class extends Dummy {
$model = new class () extends Dummy {
public $sortable = [
'order_column_name' => 'my_custom_order_column',
'sort_when_creating' => false,
Expand Down

0 comments on commit 64a3365

Please sign in to comment.