Skip to content
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
2 changes: 1 addition & 1 deletion src/_apis/detail/get-crew-detail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ type CrewDetail = {
};

export async function getCrewDetail(): Promise<CrewDetail> {
const response = await fetchApi<CrewDetail>('/api/mock-api/detail?type=crewDetail', {
const response = await fetchApi<CrewDetail>('/api/mock-api/detail?type=crewDetails', {
method: 'GET',
headers: {
'Content-Type': 'application/json',
Expand Down
6 changes: 3 additions & 3 deletions src/app/api/mock-api/detail/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { CrewReviewData } from '@/src/mock/review-data';
// FIX: 데이터 패칭 확인을 μœ„ν•œ λͺ© api μΆ”ν›„ μ‚­μ œ μ˜ˆμ •

const data = {
crewDetail: {
crewDetails: {
id: 1,
title: '크루 제λͺ© 제λͺ© 제λͺ©',
mainLocation: 'μ„œμšΈνŠΉλ³„μ‹œ',
Expand Down Expand Up @@ -130,8 +130,8 @@ export async function GET(req: Request) {

// type에 따라 λ‹€λ₯Έ 데이터 λ°˜ν™˜
switch (type) {
case 'crewDetail':
return NextResponse.json(data.crewDetail);
case 'crewDetails':
return NextResponse.json(data.crewDetails);
case 'gatherings':
return NextResponse.json(data.gatherings);
case 'gatheringDetail':
Expand Down