Skip to content

Commit 8528973

Browse files
authored
Merge pull request #36 from DevKor-github/feature/kakao-done
fix: @이번 주 redirect url 변경
2 parents 6abd44d + a176d41 commit 8528973

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

src/main/java/com/workingdead/meet/controller/RedirectController.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ public class RedirectController {
1919

2020
private final VoteService voteService;
2121

22+
@org.springframework.beans.factory.annotation.Value("${whend.frontend-base-url}")
23+
private String frontendBaseUrl;
24+
2225
/**
2326
* 카카오 챗봇 버튼 클릭 시 호출되는 리다이렉트 엔드포인트
2427
* - botGroupKey(채팅방 ID)를 기준으로 활성 투표를 조회
@@ -33,7 +36,7 @@ public ResponseEntity<Void> openVote(
3336
Vote vote = voteService.findActiveVoteByBotGroupKey(botGroupKey);
3437

3538
// 2) 웹으로 redirect (web 라우트: /{shareCode})
36-
URI target = URI.create("https://whendy.netlify.app/" + vote.getCode()
39+
URI target = URI.create(frontendBaseUrl + "/" + vote.getCode()
3740
+ "?botUserKey=" + URLEncoder.encode(botUserKey, UTF_8)
3841
);
3942
return ResponseEntity.status(302).location(target).build();

src/main/resources/application.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,4 +72,7 @@ kakao:
7272
event-api-key: ${KAKAO_EVENT_API_KEY:}
7373
bot-base-url: ${KAKAO_BOT_BASE_URL:}
7474
channel-id: ${KAKAO_CHANNEL_ID:}
75-
bot-id: ${KAKAO_BOT_ID:}
75+
bot-id: ${KAKAO_BOT_ID:}
76+
77+
whend:
78+
frontend-base-url: https://whendy.netlify.app

0 commit comments

Comments
 (0)