Skip to content

Commit

Permalink
fix when there are no segments
Browse files Browse the repository at this point in the history
  • Loading branch information
hanydd committed Jan 16, 2025
1 parent 9db4114 commit a041514
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/requests/segments.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ export async function getSegmentsByVideoID(

const responseSegments: SegmentResponse = { segments: null, status: response.status };
if (!response?.ok) {
segmentCache.set(videoID, responseSegments);
return responseSegments;
}
const allSegments: SponsorTimeHashedID[] = JSON.parse(response?.responseText);
Expand Down

0 comments on commit a041514

Please sign in to comment.