From b3b4949f2f7b23299bcae62fbb10e1638662db6c Mon Sep 17 00:00:00 2001 From: WooJin Kong Date: Wed, 10 Jun 2026 16:43:38 +0900 Subject: [PATCH 1/3] =?UTF-8?q?fix:=20=EC=98=81=EC=96=91=EC=82=AC=20?= =?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=80=20=EC=9D=B4=EB=AF=B8=EC=A7=80=20?= =?UTF-8?q?=EB=8B=A4=EC=9A=B4=EB=A1=9C=EB=93=9C=20=EC=8B=A4=ED=8C=A8=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../koreatech/koin/domain/coop/service/CoopService.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java b/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java index e90c020e36..2e3b60a0f6 100644 --- a/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java +++ b/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java @@ -6,6 +6,8 @@ import java.io.ByteArrayOutputStream; import java.io.File; import java.io.IOException; +import java.io.UnsupportedEncodingException; +import java.net.URLDecoder; import java.time.Clock; import java.time.LocalDate; import java.time.LocalDateTime; @@ -537,7 +539,12 @@ private String convertFileName(Dining dining, String s3Key) { private String extractS3KeyFrom(String imageUrl) { // URL format: https:/// String cdnPath = s3Client.getDomainUrlPrefix(); - return imageUrl.substring(imageUrl.indexOf(cdnPath) + cdnPath.length()); + String encodedKey = imageUrl.substring(imageUrl.indexOf(cdnPath) + cdnPath.length()); + try { + return URLDecoder.decode(encodedKey, "UTF-8"); + } catch (UnsupportedEncodingException e) { + throw new KoinIllegalStateException("Response to String convert exception: " + e.getMessage()); + } } private void preprocessPath(File localImageDirectory, File zipFilePath) { From 07e18364c1096cc6ad39ea0a79511a37d1ee9147 Mon Sep 17 00:00:00 2001 From: WooJin Kong Date: Wed, 10 Jun 2026 16:46:18 +0900 Subject: [PATCH 2/3] =?UTF-8?q?chore:=20=EC=97=90=EB=9F=AC=20=EB=A9=94?= =?UTF-8?q?=EC=8B=9C=EC=A7=80=20=ED=95=9C=EA=B8=80=EB=A1=9C=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/in/koreatech/koin/domain/coop/service/CoopService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java b/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java index 2e3b60a0f6..2e4b9e2952 100644 --- a/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java +++ b/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java @@ -543,7 +543,7 @@ private String extractS3KeyFrom(String imageUrl) { try { return URLDecoder.decode(encodedKey, "UTF-8"); } catch (UnsupportedEncodingException e) { - throw new KoinIllegalStateException("Response to String convert exception: " + e.getMessage()); + throw new KoinIllegalStateException("Key 디코딩 중 문제가 발생했습니다. " + e.getMessage()); } } From f6364d142c6165b5a8b93b8bf71093e6a0cad6bc Mon Sep 17 00:00:00 2001 From: WooJin Kong Date: Wed, 10 Jun 2026 16:59:50 +0900 Subject: [PATCH 3/3] =?UTF-8?q?fix:=20=EB=B6=88=ED=95=84=EC=9A=94=ED=95=9C?= =?UTF-8?q?=20try/catch=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../koreatech/koin/domain/coop/service/CoopService.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java b/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java index 2e4b9e2952..6bcb4c295a 100644 --- a/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java +++ b/src/main/java/in/koreatech/koin/domain/coop/service/CoopService.java @@ -6,8 +6,8 @@ import java.io.ByteArrayOutputStream; import java.io.File; import java.io.IOException; -import java.io.UnsupportedEncodingException; import java.net.URLDecoder; +import java.nio.charset.StandardCharsets; import java.time.Clock; import java.time.LocalDate; import java.time.LocalDateTime; @@ -540,11 +540,7 @@ private String extractS3KeyFrom(String imageUrl) { // URL format: https:/// String cdnPath = s3Client.getDomainUrlPrefix(); String encodedKey = imageUrl.substring(imageUrl.indexOf(cdnPath) + cdnPath.length()); - try { - return URLDecoder.decode(encodedKey, "UTF-8"); - } catch (UnsupportedEncodingException e) { - throw new KoinIllegalStateException("Key 디코딩 중 문제가 발생했습니다. " + e.getMessage()); - } + return URLDecoder.decode(encodedKey, StandardCharsets.UTF_8); } private void preprocessPath(File localImageDirectory, File zipFilePath) {