Fix cannot update upload overall marhun photo

This commit is contained in:
afiq.hamzah
2022-11-24 14:19:24 +08:00
parent f6f0cca41c
commit 50ca8f58bf
3 changed files with 9 additions and 9 deletions
+3 -1
View File
@@ -5,6 +5,7 @@ namespace App\Services;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Storage;
use App\Models\FileMarhun;
use App\Models\LelongBid;
class MarhunPhotoService
{
@@ -12,6 +13,7 @@ class MarhunPhotoService
public function store(Request $request)
{
$file_type = $request->gambarMarhun->extension();
$addfile = new FileMarhun();
@@ -52,7 +54,7 @@ class MarhunPhotoService
$marhunImageFileName = "overall.{$imageExtension}";
if (!empty($request->lelongbidmarhund_id)) {
if (!empty($request->lelongbidmarhun_id)) {
$marhunImageFileName = "$lelongbidmarhun_id.$imageExtension";
}