diff --git a/app/Models/Component.php b/app/Models/Component.php index 03b611f3..6fbe8d97 100644 --- a/app/Models/Component.php +++ b/app/Models/Component.php @@ -147,11 +147,11 @@ class Component extends Model implements HasPresenter /** * Get the tags relation. * - * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany + * @return \Illuminate\Database\Eloquent\Relations\MorphMany */ public function tags() { - return $this->belongsToMany(Tag::class); + return $this->morphMany(Taggable::class, 'taggable'); } /**