Andrew 2 månader sedan
förälder
incheckning
5e28f639da
1 ändrade filer med 5 tillägg och 5 borttagningar
  1. 5
    5
      app/Models/Album.php

+ 5
- 5
app/Models/Album.php Visa fil

@@ -29,25 +29,25 @@ class Album extends Model
29 29
     protected function albumImgPcUrl(): Attribute
30 30
     {
31 31
         return Attribute::make(
32
-            get: fn ($value) => is_null($this->news_img_pc) ? null :Storage::disk('s3')->url($this->news_img_pc),
32
+            get: fn ($value) => is_null($this->news_img_pc) ? null :Storage::url($this->news_img_pc),
33 33
         );
34 34
     }
35 35
     protected function albumImgMobileUrl(): Attribute
36 36
     {
37 37
         return Attribute::make(
38
-            get: fn ($value) => is_null($this->news_img_mobile) ? null :Storage::disk('s3')->url($this->news_img_mobile),
38
+            get: fn ($value) => is_null($this->news_img_mobile) ? null :Storage::url($this->news_img_mobile),
39 39
         );
40 40
     }
41 41
     protected function albumMetaImg(): Attribute
42 42
     {
43 43
         return Attribute::make(
44
-            get: fn ($value) => is_null($this->meta_img) ? null :Storage::disk('s3')->url($this->meta_img),
44
+            get: fn ($value) => is_null($this->meta_img) ? null :Storage::url($this->meta_img),
45 45
         );
46 46
     }
47 47
     protected function albumImgBannerUrl(): Attribute
48 48
     {
49 49
         return Attribute::make(
50
-            get: fn ($value) => is_null($this->news_banner) ? null :Storage::disk('s3')->url($this->news_banner),
50
+            get: fn ($value) => is_null($this->news_banner) ? null :Storage::url($this->news_banner),
51 51
         );
52 52
     }
53 53
     protected function albumUploadType(): Attribute
@@ -66,7 +66,7 @@ class Album extends Model
66 66
     protected function albumVideoLink(): Attribute
67 67
     {
68 68
         return Attribute::make(
69
-            get: fn ($value) => ($this->attributes["upload_type"] == 2) ? Storage::disk('s3')->url($this->attributes["link"]) : $this->attributes["link"],
69
+            get: fn ($value) => ($this->attributes["upload_type"] == 2) ? Storage::url($this->attributes["link"]) : $this->attributes["link"],
70 70
         );
71 71
     }
72 72
     public function homepageToTop()