File tree Expand file tree Collapse file tree 3 files changed +8
-13
lines changed Expand file tree Collapse file tree 3 files changed +8
-13
lines changed Original file line number Diff line number Diff line change 1
1
<?php
2
2
3
3
use Rector \CodeQuality \Rector \FunctionLike \SimplifyUselessVariableRector ;
4
+ use Rector \CodingStyle \Rector \Assign \SplitDoubleAssignRector ;
4
5
use Rector \CodingStyle \Rector \Closure \StaticClosureRector ;
5
6
use Rector \CodingStyle \Rector \Encapsed \EncapsedStringsToSprintfRector ;
6
7
use Rector \CodingStyle \Rector \If_ \NullableCompareToNullRector ;
30
31
NullableCompareToNullRector::class,
31
32
EncapsedStringsToSprintfRector::class,
32
33
StaticClosureRector::class,
34
+ SplitDoubleAssignRector::class,
33
35
]);
Original file line number Diff line number Diff line change @@ -70,8 +70,7 @@ public function getPropertiesFromTable($model): void
70
70
$ column_name = $ column ->name ;
71
71
72
72
if (in_array ($ column_name , $ model ->getDates (), true )) {
73
- $ get_type = \Illuminate \Support \Carbon::class;
74
- $ set_type = \Illuminate \Support \Carbon::class;
73
+ $ get_type = $ set_type = \Illuminate \Support \Carbon::class;
75
74
} else {
76
75
switch ($ column ->type ) {
77
76
case SchemaColumn::TYPE_STRING :
@@ -89,27 +88,23 @@ public function getPropertiesFromTable($model): void
89
88
$ get_type = '0|1 ' ;
90
89
break ;
91
90
default :
92
- $ get_type = 'bool ' ;
93
- $ set_type = 'bool ' ;
91
+ $ get_type = $ set_type = 'bool ' ;
94
92
break ;
95
93
}
96
94
97
95
break ;
98
96
99
97
case SchemaColumn::TYPE_ENUM :
100
98
if (!$ column ->options ) {
101
- $ get_type = 'string ' ;
102
- $ set_type = 'string ' ;
99
+ $ get_type = $ set_type = 'string ' ;
103
100
} else {
104
- $ get_type = "' " . implode ("'|' " , $ column ->options ) . "' " ;
105
- $ set_type = "' " . implode ("'|' " , $ column ->options ) . "' " ;
101
+ $ get_type = $ set_type = "' " . implode ("'|' " , $ column ->options ) . "' " ;
106
102
}
107
103
108
104
break ;
109
105
110
106
default :
111
- $ get_type = SchemaColumn::TYPE_MIXED ;
112
- $ set_type = SchemaColumn::TYPE_MIXED ;
107
+ $ get_type = $ set_type = SchemaColumn::TYPE_MIXED ;
113
108
break ;
114
109
}
115
110
}
Original file line number Diff line number Diff line change @@ -76,10 +76,8 @@ public static function getAppFullyQualifiedClassName(): string
76
76
/**
77
77
* Overrides {@see \Orchestra\Testbench\Concerns\CreatesApplication::resolveApplicationBootstrappers}
78
78
* Resolve application bootstrapper.
79
- *
80
- * @param LaravelApplication $app
81
79
*/
82
- protected function resolveApplicationBootstrappers ($ app ): void
80
+ protected function resolveApplicationBootstrappers (LaravelApplication $ app ): void
83
81
{
84
82
// we want to keep the default psalm exception handler, otherwise the Laravel one will always return exit codes
85
83
// of 0
You can’t perform that action at this time.
0 commit comments