mirror of
https://github.com/barryvdh/laravel-ide-helper.git
synced 2026-08-18 18:13:11 +00:00
@@ -356,6 +356,7 @@ class ModelsCommand extends Command
|
||||
'belongsToMany',
|
||||
'hasOne',
|
||||
'belongsTo',
|
||||
'morphOne',
|
||||
'morphTo',
|
||||
'morphMany',
|
||||
'morphToMany'
|
||||
@@ -377,6 +378,9 @@ class ModelsCommand extends Command
|
||||
true,
|
||||
null
|
||||
);
|
||||
} elseif ($relation === "morphTo") {
|
||||
// Model isn't specified because relation is polymorphic
|
||||
$this->setProperty($method, '\Illuminate\Database\Eloquent\Model|\Eloquent', true, null);
|
||||
} else {
|
||||
//Single model is returned
|
||||
$this->setProperty($method, $relatedModel, true, null);
|
||||
|
||||
Reference in New Issue
Block a user