fix: maxRetries set to 3
since max limit is 3
This commit is contained in:
@@ -183,8 +183,10 @@ app.openapi(route, async (c) => {
|
||||
const isAnifyEnabled = readEnvVariable<boolean>(c.env, "ENABLE_ANIFY");
|
||||
let result: FetchUrlResponse | null;
|
||||
if (provider) {
|
||||
console.log(`Fetching sources from ${provider} for ${aniListId}`);
|
||||
result = await fetchEpisodeUrl(provider, id, aniListId, isAnifyEnabled);
|
||||
} else {
|
||||
console.log(`Fetching sources from all providers for ${aniListId}`);
|
||||
const { fetchUrlResult } = await fetchEpisodeUrlFromAllProviders(
|
||||
aniListId,
|
||||
episodeNumber!,
|
||||
|
||||
@@ -43,7 +43,7 @@ export async function maybeScheduleNextAiringEpisode(
|
||||
const { messageId } = await client.publishJSON({
|
||||
url: `${domain}/internal/new-episode`,
|
||||
body: { aniListId, episodeNumber: nextEpisode },
|
||||
retries: 6,
|
||||
retries: 3,
|
||||
notBefore: airingAt,
|
||||
});
|
||||
await Promise.allSettled([
|
||||
|
||||
@@ -92,7 +92,7 @@ async function triggerNextEpisodeRoute(titleId: number) {
|
||||
aniListId: titleId,
|
||||
episodeNumber: mostRecentEpisodeNumber,
|
||||
},
|
||||
retries: 6,
|
||||
retries: 3,
|
||||
})
|
||||
.then(() => true)
|
||||
.catch((error) => {
|
||||
@@ -124,7 +124,7 @@ async function triggerNextEpisodeRoute(titleId: number) {
|
||||
aniListId: titleId,
|
||||
episodeNumber: title.nextAiringEpisode.episode,
|
||||
},
|
||||
retries: 6,
|
||||
retries: 3,
|
||||
notBefore: title.nextAiringEpisode.airingAt,
|
||||
})
|
||||
.then(() => true)
|
||||
|
||||
Reference in New Issue
Block a user