From e764b6e8b33985e13029dc18478eb6f1d5dc62c0 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Sat, 12 Jan 2019 13:34:10 -0700 Subject: [PATCH] Update StoryItem model --- app/StoryItem.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/app/StoryItem.php b/app/StoryItem.php index 885006968..263605768 100644 --- a/app/StoryItem.php +++ b/app/StoryItem.php @@ -3,6 +3,7 @@ namespace App; use Illuminate\Database\Eloquent\Model; +use Storage; class StoryItem extends Model { @@ -10,4 +11,9 @@ class StoryItem extends Model { return $this->belongsTo(Story::class); } + + public function url() + { + return Storage::url($this->media_path); + } }