Skip to content

Commit

Permalink
feat(panel-api): 패널 가져오기 API에서 result로 분해하지 않는다 (#345)
Browse files Browse the repository at this point in the history
  • Loading branch information
leegwae committed Aug 15, 2023
1 parent 573c9a8 commit 3c1975a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/lib/api/__tests__/panel.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,6 @@ describe('panel api', () => {
const panelId = faker.datatype.uuid();

const res = await getPanel(panelId);
expect(res.id).toBe(panelId);
expect(res.result.id).toBe(panelId);
});
});
6 changes: 2 additions & 4 deletions src/lib/api/panel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,8 @@ export const deletePanel = async (

export const getPanel = async (
panelId: GetPanelPathParams['panelId'],
): Promise<GetPanelResult> =>
apiClient
.get<GetPanelResponse>(apiUrl.panel.get(panelId))
.then((data) => data.result);
): Promise<GetPanelResponse> =>
apiClient.get<GetPanelResponse>(apiUrl.panel.get(panelId));

export const getMyPanels = async (
params: GetMyPanelsParams,
Expand Down

0 comments on commit 3c1975a

Please sign in to comment.