File tree Expand file tree Collapse file tree 2 files changed +15
-26
lines changed
tests/Console/ModelsCommand/Attributes Expand file tree Collapse file tree 2 files changed +15
-26
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,13 @@ public function uppercaseName(): Attribute
2828 });
2929 }
3030
31+ public function lowercaseName (): Attribute
32+ {
33+ return Attribute::get (function () {
34+ return strtolower ($ this ->name );
35+ });
36+ }
37+
3138 /**
3239 * ide-helper does not recognize this method being an Attribute
3340 * because the method has no actual return type;
@@ -47,17 +54,4 @@ function (?string $value): ?string {
4754 }
4855 );
4956 }
50-
51- /**
52- * ide-helper does not recognize this method being an Attribute
53- * because the callable has no specified return type;
54- *
55- * @return \Illuminate\Database\Eloquent\Casts\Attribute
56- */
57- public function alsoNotAnAttribute (): Attribute
58- {
59- return Attribute::get (function () {
60- return strtoupper ($ this ->name );
61- });
62- }
6357}
Original file line number Diff line number Diff line change 1111 * Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\Attributes\Models\Simple
1212 *
1313 * @property integer $id
14+ * @property-read mixed $lowercase_name
1415 * @property string|null $name
1516 * @property-read string $uppercase_name
1617 * @method static \Illuminate\Database\Eloquent\Builder|Simple newModelQuery()
@@ -40,6 +41,13 @@ public function uppercaseName(): Attribute
4041 });
4142 }
4243
44+ public function lowercaseName (): Attribute
45+ {
46+ return Attribute::get (function () {
47+ return strtolower ($ this ->name );
48+ });
49+ }
50+
4351 /**
4452 * ide-helper does not recognize this method being an Attribute
4553 * because the method has no actual return type;
@@ -59,17 +67,4 @@ function (?string $value): ?string {
5967 }
6068 );
6169 }
62-
63- /**
64- * ide-helper does not recognize this method being an Attribute
65- * because the callable has no specified return type;
66- *
67- * @return \Illuminate\Database\Eloquent\Casts\Attribute
68- */
69- public function alsoNotAnAttribute (): Attribute
70- {
71- return Attribute::get (function () {
72- return strtoupper ($ this ->name );
73- });
74- }
7570}
You can’t perform that action at this time.
0 commit comments