Fix exception that occurs with a chapter is skipped

This commit is contained in:
Dave Nesbitt 2025-01-20 15:26:45 +01:00
parent 173e2fb4c9
commit 8ed8db5526

View file

@ -58,6 +58,7 @@ def main(kokoro, file_path, lang, voice, pick_manually, speed):
if len(text.strip()) < 10:
print(f'Skipping empty chapter {i}')
i += 1
chapter_mp3_files.remove(chapter_filename)
continue
print(f'Reading chapter {i} ({len(text):,} characters)...')
if i == 1: