Skip to content

Commit

Permalink
fix get movie cover size
Browse files Browse the repository at this point in the history
  • Loading branch information
ovnrain committed Jun 13, 2024
1 parent 149a287 commit d5f4b17
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions api/javbusParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -310,8 +310,17 @@ export async function getMovieDetail(id: string): Promise<MovieDetail> {
let imageSize: ImageSize | null = null;

if (img) {
const { width, height } = await probe(img, { agent });
imageSize = { width, height };
try {
const { width, height } = await probe(img, {
agent,
cookies: {
existmag: 'mag',
},
});
imageSize = { width, height };
} catch (e) {
//
}
}

/* ----------------- 基本信息 ------------------ */
Expand Down

0 comments on commit d5f4b17

Please sign in to comment.