File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed
tests/Console/ModelsCommand/GeneratePhpdocWithMixin/__snapshots__ Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -1081,9 +1081,11 @@ protected function createPhpDocs($class)
1081
1081
}
1082
1082
1083
1083
$ classname = $ this ->write_mixin ? $ mixinClassName : $ classname ;
1084
- $ output = "namespace {$ namespace }{ \n{$ docComment }\n\t{$ keyword }class {$ classname } " ;
1085
1084
1086
- if (!$ this ->write_mixin ) {
1085
+ $ allowDynamicAttributes = $ this ->write_mixin ? "#[\AllowDynamicProperties] \n\t" : '' ;
1086
+ $ output = "namespace {$ namespace }{ \n{$ docComment }\n\t{$ keyword }{$ allowDynamicAttributes }class {$ classname } " ;
1087
+
1088
+ if (! $ this ->write_mixin ) {
1087
1089
$ output .= "extends \Eloquent " ;
1088
1090
1089
1091
if ($ interfaceNames ) {
Original file line number Diff line number Diff line change @@ -184,6 +184,7 @@ class Post extends Model
184
184
* @method static \Illuminate\Database\Eloquent\Builder|Post whereYearNullable($value)
185
185
* @mixin \Eloquent
186
186
*/
187
+ #[\AllowDynamicProperties]
187
188
class IdeHelperPost {}
188
189
}
189
190
You can’t perform that action at this time.
0 commit comments