fix(route/fanbox) Update PostListResponse model to conform to new API response (#22828)
Co-authored-by: Sryvkver <git@sryvkver.com>
This commit is contained in:
parent
2221f62bdb
commit
c0825f01dd
|
|
@ -81,7 +81,7 @@ async function handler(ctx: Context): Promise<Data> {
|
|||
|
||||
let items: DataItem[];
|
||||
try {
|
||||
items = await Promise.all(postListResponse.body.map((i) => parseItem(page, i)));
|
||||
items = await Promise.all(postListResponse.body.posts.map((i) => parseItem(page, i)));
|
||||
} finally {
|
||||
await page.close();
|
||||
await context.close();
|
||||
|
|
|
|||
|
|
@ -25,7 +25,9 @@ export interface UserInfoResponse {
|
|||
}
|
||||
|
||||
export interface PostListResponse {
|
||||
body: PostItem[];
|
||||
body: {
|
||||
posts: PostItem[];
|
||||
};
|
||||
}
|
||||
|
||||
export interface PostDetailResponse {
|
||||
|
|
|
|||
Loading…
Reference in New Issue