Closed jdanino closed 2 years ago
Hi @barryvdh, confirming this fixed the deprecation warning. Thanks.
ReflectionClass::__construct(): Passing null to parameter #1 ($objectOrClass)
of type object|string is deprecated in
/vendor/barryvdh/laravel-ide-helper/src/Console/MetaCommand.php on line 98
If it's null, it wouldn't make sense to try to make a reflection of it, right?
Agreed, if the line above
$concrete = $this->laravel->make($abstract);
produces null
in $concrete
, something else is weird
Superseded by https://github.com/barryvdh/laravel-ide-helper/pull/1351 which gives more details what's going on and does not silently coerce null into ''
, thank you though for this PR 🙏🏼
Summary
Fixed a deprecation warning because of a nullable parameter to the reflection class constructor by adding and emtyp string as a default.
ReflectionClass::__construct(): Passing null to parameter #1 ($objectOrClass) of type object|string is deprecated
Type of change