diff --git a/app/Models/Attachment.php b/app/Models/Attachment.php index b1bc6f2..d63355d 100644 --- a/app/Models/Attachment.php +++ b/app/Models/Attachment.php @@ -25,4 +25,13 @@ class Attachment extends Model public function attachable() { return $this->morphTo(); - }} + } + + /** + * Get the media for this attachment. + */ + public function media() + { + return $this->belongsTo(Media::class); + } +} \ No newline at end of file