mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-09 20:29:36 +02:00
Fix SS album detail response
This commit is contained in:
@@ -200,7 +200,8 @@ const getAlbumDetail = async (args: AlbumDetailArgs): Promise<SSAlbumDetail> =>
|
|||||||
})
|
})
|
||||||
.json<SSAlbumDetailResponse>();
|
.json<SSAlbumDetailResponse>();
|
||||||
|
|
||||||
return data.album;
|
const { song: songs, ...dataWithoutSong } = data.album;
|
||||||
|
return { ...dataWithoutSong, songs };
|
||||||
};
|
};
|
||||||
|
|
||||||
const getAlbumList = async (args: AlbumListArgs): Promise<SSAlbumList> => {
|
const getAlbumList = async (args: AlbumListArgs): Promise<SSAlbumList> => {
|
||||||
|
|||||||
@@ -55,7 +55,7 @@ export type SSAlbumListResponse = {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
export type SSAlbumDetail = SSAlbum;
|
export type SSAlbumDetail = Omit<SSAlbum, 'song'> & { songs: SSSong[] };
|
||||||
|
|
||||||
export type SSAlbumDetailResponse = {
|
export type SSAlbumDetailResponse = {
|
||||||
album: SSAlbum;
|
album: SSAlbum;
|
||||||
|
|||||||
Reference in New Issue
Block a user