Skip to content

Commit 00ffb0b

Browse files
authored
Merge pull request #11 from cesargb/analysis-Vrmjx6
Apply fixes from StyleCI
2 parents 6c8418f + a16e20d commit 00ffb0b

File tree

4 files changed

+20
-21
lines changed

4 files changed

+20
-21
lines changed

src/CascadeDelete.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ public function getCascadeDeleteMorph()
3333
* Clean residual morph relation from a model. Return number
3434
* of deleted rows.
3535
*
36-
* @param bool $dryRun
36+
* @param bool $dryRun
3737
* @return int
3838
*/
3939
public function deleteMorphResidual(bool $dryRun = false)

src/Events/RelationMorphFromModelWasCleaned.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ class RelationMorphFromModelWasCleaned
1818
/**
1919
* Event dispach when clean relations morph from model.
2020
*
21-
* @param Model $model
22-
* @param Relation $relation
23-
* @param int $numDeleted
24-
* @param bool $dryRun
21+
* @param Model $model
22+
* @param Relation $relation
23+
* @param int $numDeleted
24+
* @param bool $dryRun
2525
*/
2626
public function __construct(Model $model, Relation $relation, int $numDeleted, bool $dryRun)
2727
{

src/Morph.php

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class Morph
1616
/**
1717
* Delete polymorphic relationships of the single records from Model.
1818
*
19-
* @param \Illuminate\Database\Eloquent\Model $model
19+
* @param \Illuminate\Database\Eloquent\Model $model
2020
* @return void
2121
*/
2222
public function delete($model)
@@ -33,7 +33,7 @@ public function delete($model)
3333
/**
3434
* Clean residual polymorphic relationships from all Models.
3535
*
36-
* @param bool $dryRun
36+
* @param bool $dryRun
3737
* @return int Num rows was deleted
3838
*/
3939
public function cleanResidualAllModels(bool $dryRun = false)
@@ -50,8 +50,8 @@ public function cleanResidualAllModels(bool $dryRun = false)
5050
/**
5151
* Clean residual polymorphic relationships from a Model.
5252
*
53-
* @param Model $model
54-
* @param bool $dryRun
53+
* @param Model $model
54+
* @param bool $dryRun
5555
* @return int Num rows was deleted
5656
*/
5757
public function cleanResidualByModel($model, bool $dryRun = false)
@@ -95,9 +95,9 @@ function ($modelName) {
9595
/**
9696
* Query to clean orphan morph table.
9797
*
98-
* @param Model $parentModel
99-
* @param MorphOneOrMany|MorphToMany $relation
100-
* @param bool $dryRun
98+
* @param Model $parentModel
99+
* @param MorphOneOrMany|MorphToMany $relation
100+
* @param bool $dryRun
101101
* @return int Num rows was deleted
102102
*/
103103
protected function queryCleanOrphan(Model $parentModel, Relation $relation, bool $dryRun = false)
@@ -124,7 +124,7 @@ protected function queryCleanOrphan(Model $parentModel, Relation $relation, bool
124124
/**
125125
* Get table and fields from morph relation.
126126
*
127-
* @param MorphOneOrMany|MorphToMany $relation
127+
* @param MorphOneOrMany|MorphToMany $relation
128128
* @return array [$table, $fieldType, $fieldId]
129129
*/
130130
protected function getStructureMorphRelation(Relation $relation): array
@@ -163,7 +163,7 @@ class_uses($class)
163163
/**
164164
* Fetch polymorphic relationships from a Model.
165165
*
166-
* @param \Illuminate\Database\Eloquent\Model $model
166+
* @param \Illuminate\Database\Eloquent\Model $model
167167
* @return array
168168
*/
169169
protected function getValidMorphRelationsFromModel($model)
@@ -184,8 +184,8 @@ function ($relation) {
184184
/**
185185
* Verify if method of a Model return a polymorphic relationship.
186186
*
187-
* @param \Illuminate\Database\Eloquent\Model $model
188-
* @param string $methodName
187+
* @param \Illuminate\Database\Eloquent\Model $model
188+
* @param string $methodName
189189
* @return bool
190190
*/
191191
protected function methodReturnedMorphRelation($model, $methodName)
@@ -202,7 +202,7 @@ protected function methodReturnedMorphRelation($model, $methodName)
202202
/**
203203
* Verify if a object is a instance of a polymorphic relationship.
204204
*
205-
* @param mixed $relation
205+
* @param mixed $relation
206206
* @return bool
207207
*/
208208
protected function isMorphRelation($relation)
@@ -213,7 +213,7 @@ protected function isMorphRelation($relation)
213213
/**
214214
* Load models with Cascade Delete.
215215
*
216-
* @param array|string $path
216+
* @param array|string $path
217217
* @return void
218218
*/
219219
protected function load()

tests/TestCase.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ protected function setUp(): void
2424
}
2525

2626
/**
27-
* @param \Illuminate\Foundation\Application $app
28-
*
27+
* @param \Illuminate\Foundation\Application $app
2928
* @return array
3029
*/
3130
protected function getPackageProviders($app)
@@ -56,7 +55,7 @@ protected function getEnvironmentSetUp($app)
5655
/**
5756
* Set up the database.
5857
*
59-
* @param \Illuminate\Foundation\Application $app
58+
* @param \Illuminate\Foundation\Application $app
6059
*/
6160
protected function setUpDatabase($app)
6261
{

0 commit comments

Comments
 (0)