fix: fix reference to model classes

This commit is contained in:
fiachra mcdermott 2021-06-21 18:41:08 -07:00
parent c62c126b81
commit 1badb873a4
2 changed files with 2 additions and 4 deletions

View File

@ -11,6 +11,7 @@ use Illuminate\Database\Eloquent\Relations\MorphToMany;
use PhpParser;
use Psalm\Context;
use Psalm\CodeLocation;
use Psalm\LaravelPlugin\Providers\ModelStubProvider;
use Psalm\Type;
use Psalm\StatementsSource;
use function in_array;
@ -27,7 +28,7 @@ class ModelPropertyHandler implements
/** @return array<string, string> */
public static function getClassLikeNames() : array
{
return \Psalm\LaravelPlugin\Plugin::$model_classes;
return ModelStubProvider::getModelClasses();
}
/**

View File

@ -21,9 +21,6 @@ use function glob;
class Plugin implements PluginEntryPointInterface
{
/** @var array<string> */
public static $model_classes = [];
public function __invoke(RegistrationInterface $registration, ?SimpleXMLElement $config = null) : void
{
try {