Skip to content

Commit

Permalink
Merge pull request #54 from KTwizviz/WV-46-fix-mixed-content-error
Browse files Browse the repository at this point in the history
🔧 [WV-46] fix : 머지된 API 엔드포인트 수정
  • Loading branch information
hee2323 authored Jan 16, 2025
2 parents 536053c + cc5b3b7 commit b4aa61b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions api/news/apis.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
const BASE_URL = process.env.NEXT_PUBLIC_API_KEY;

// news-detail
export const getNewsDetail = async (
artcSeq: string
): Promise<ArticleContentsResponse["data"]> => {
const queryparam = artcSeq ? `newsdetail?artcSeq=${artcSeq}` : "";

const url = `${BASE_URL}/article/${queryparam}`;
const url = `/api/article/${queryparam}`;
const res = await fetch(url);

if (!res.ok) {
Expand Down
2 changes: 1 addition & 1 deletion api/player/apis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export const getPitcherDetail = async (
pcode: string
): Promise<PitcherDetailResponse["data"]> => {
const queryparam = pcode ? `pitcherdetail?pcode=${pcode}` : "";
const url = `${BASE_URL}/player/${queryparam}`;
const url = `/api/player/${queryparam}`;
const response = await fetch(url, { method: "GET" });

if (!response.ok) {
Expand Down

0 comments on commit b4aa61b

Please sign in to comment.