Skip to content

Commit

Permalink
Merge pull request #45 from andes2912/feature/about
Browse files Browse the repository at this point in the history
Bug Fix Update Visi & Misi Backend
  • Loading branch information
andes2912 authored Mar 28, 2022
2 parents bc17303 + be12639 commit 95f78a3
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,10 @@ public function update(VisidanMisiRequest $request, $id)
$image->storeAs($tujuan_upload,$nama_img);
}

$visimisi = new Visimisi();
$visimisi = Visimisi::find($id);
$visimisi->visi = $request->visi;
$visimisi->misi = $request->misi;
$visimisi->image = $nama_img;
$visimisi->image = $nama_img ?? $visimisi->image;
$visimisi->update();

Session::flash('success','Visi dan Misi Berhasil diupdate!');
Expand Down

0 comments on commit 95f78a3

Please sign in to comment.