From 40ec5ac3fe99a678ce76c10f272d637f13352b9c Mon Sep 17 00:00:00 2001 From: reddevilmidzy Date: Fri, 26 Jul 2024 10:53:56 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20CORS=20=EC=98=A4=EB=A5=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/site/coduo/pairroom/controller/PairRoomController.java | 2 +- .../coduo/referencelink/controller/ReferenceLinkController.java | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/src/main/java/site/coduo/pairroom/controller/PairRoomController.java b/backend/src/main/java/site/coduo/pairroom/controller/PairRoomController.java index 10f9b46fb..54cc5a44b 100644 --- a/backend/src/main/java/site/coduo/pairroom/controller/PairRoomController.java +++ b/backend/src/main/java/site/coduo/pairroom/controller/PairRoomController.java @@ -24,7 +24,7 @@ @RequiredArgsConstructor @RestController -@CrossOrigin(origins = "http://localhost:3000") +@CrossOrigin(origins = {"http://localhost:3000", "http://3.35.178.58"}) public class PairRoomController implements PairRoomDocs { private final PairRoomService service; diff --git a/backend/src/main/java/site/coduo/referencelink/controller/ReferenceLinkController.java b/backend/src/main/java/site/coduo/referencelink/controller/ReferenceLinkController.java index 5341a3703..5876d77d9 100644 --- a/backend/src/main/java/site/coduo/referencelink/controller/ReferenceLinkController.java +++ b/backend/src/main/java/site/coduo/referencelink/controller/ReferenceLinkController.java @@ -6,6 +6,7 @@ import jakarta.validation.Valid; import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.CrossOrigin; import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PatchMapping; @@ -23,6 +24,7 @@ @RequiredArgsConstructor @RestController +@CrossOrigin(origins = {"http://localhost:3000", "http://3.35.178.58"}) public class ReferenceLinkController implements ReferenceLinkDocs { private final ReferenceLinkService referenceLinkService;