Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

데이로그 아이템 사진 별개로 한개 추가시, 그 사진만 등록되는 버그수정 #678

Merged
merged 2 commits into from
Oct 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ const ImageInput = ({ initialImage, updateCoverImage }: ImageInputProps) => {
initialImageUrls: initialImage === null ? [] : [initialImage],
onSuccess: handleImageUrlsChange,
});

return (
<ImageUploadInput
id="cover-image-upload"
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/hooks/common/useMultipleImageUpload.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export const useMultipleImageUpload = ({
{ images: imageUploadFormData },
{
onSuccess: ({ imageUrls }) => {
if (imageUrls.length === 1) {
if (maxUploadCount === 1) {
onSuccess?.([...imageUrls]);
createToast('이미지 업로드에 성공했습니다', 'success');

Expand Down