Skip to content

Commit

Permalink
chore : imgSrc가 존재할 때만 로컬 스토리지에 이미지 url저장
Browse files Browse the repository at this point in the history
  • Loading branch information
judahhh committed Dec 4, 2023
1 parent 3c7421f commit 1d713f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pages/profile/ProfileEdit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ const ProfileEdit = () => {
formData.append('profileImage', file)
postMyProfileImage(formData)
.then(() => {
localStorage.setItem('profileImageUrl', imgSrc)
imgSrc && localStorage.setItem('profileImageUrl', imgSrc)
showToast({
message: '프로필 이미지가 수정되었습니다.',
type: 'success',
Expand Down

0 comments on commit 1d713f3

Please sign in to comment.