Explorar el Código

Update Media Model, add S3 support

Daniel Supernault hace 6 años
padre
commit
c456fa7ef1
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      app/Media.php

+ 1 - 1
app/Media.php

@@ -23,7 +23,7 @@ class Media extends Model
             $url = $this->remote_url;
         } else {
             $path = $this->media_path;
-            $url = Storage::url($path);
+            $url = $this->cdn_url ?? Storage::url($path);
         }
 
         return url($url);