Skip to content

Commit 4e19d4e

Browse files
authored
[10.x] Added getQualifiedMorphTypeName to MorphToMany (#50153)
It is in addition to qualified names for MorphToMany relations.
1 parent 0804e5f commit 4e19d4e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/Illuminate/Database/Eloquent/Relations/MorphToMany.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,16 @@ public function getMorphType()
189189
return $this->morphType;
190190
}
191191

192+
/**
193+
* Get the fully qualified morph type for the relation.
194+
*
195+
* @return string
196+
*/
197+
public function getQualifiedMorphTypeName()
198+
{
199+
return $this->qualifyPivotColumn($this->morphType);
200+
}
201+
192202
/**
193203
* Get the class name of the parent model.
194204
*

0 commit comments

Comments
 (0)