feat: Apply fixes for type errors and unused variables

This commit is contained in:
2025-06-04 11:29:18 +09:00
parent 7193dd8bb7
commit a93cfd201d
7 changed files with 25 additions and 25 deletions

View File

@ -29,18 +29,22 @@ async function main() {
pub.getMonth() === yesterday.getMonth() &&
pub.getDate() === yesterday.getDate()
) {
const already = await markAsProcessed(url, item.id);
const already = await markAsProcessed(url, item['id'] as string);
if (already) continue;
const scriptText = await openAI_GenerateScript(item);
const audioFilePath = await generateTTS(item.id, scriptText);
const scriptText = await openAI_GenerateScript({
title: item.title ?? "",
link: item.link ?? "",
contentSnippet: item.contentSnippet ?? "",
});
const audioFilePath = await generateTTS(item['id'] as string, scriptText);
await saveEpisode({
id: item.id,
title: item.title,
id: item['id'] as string,
title: item.title ?? "",
pubDate: pub.toISOString(),
audioPath: audioFilePath,
sourceLink: item.link,
sourceLink: item.link ?? "",
});
}
}