test
This commit is contained in:
@@ -45,10 +45,13 @@ class Slider extends Model
|
||||
public function getImage(): string
|
||||
{
|
||||
if (!empty($this->image)) {
|
||||
if (in_array(config('filesystems.default'), ['s3', 'minio'])) {
|
||||
return Storage::url($this->image);
|
||||
if (in_array(env('FILESYSTEM_DISK'), ['s3', 'minio'])) {
|
||||
return Storage::temporaryUrl(
|
||||
$this->image,
|
||||
Date::now()->addMinutes(5)
|
||||
);
|
||||
}
|
||||
return config('app.url') . '/' . $this->image;
|
||||
return $this->image;
|
||||
}
|
||||
|
||||
return '/images/nophoto.jpg';
|
||||
|
||||
Reference in New Issue
Block a user