-
Notifications
You must be signed in to change notification settings - Fork 386
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes m4b chapters only taken from first file. #1456
Conversation
There are some cases where the chapters are embedded in every audio file the same. This is assuming that each audio file has its own separate chapters, which is what makes the most sense but is not guaranteed. |
Interesting. Or do you mean that those chapters actually span multiple files already? If so I guess I could check that the last chapter is contained within the file duration. And if not. I guess the check would be to compare the last chapters start/end to the previous file. |
@advplyr Added a check that keeps original implementation when the first and second audio files chapters titles are the same. Is there a way to re-parse chapters for a book? |
Thanks, this should do it. The chapters are only parsed again if any of the audio files are updated. This can be improved but we want to make sure to not overwrite changes someone made in the chapter editor that haven't yet been embedded. |
This is in |
Noticed that I was only getting chapters from the first
m4b
file and this fixes that.Only tested with
m4b
. Don't know if other file formats support chapters.Code uses
let
and optional chaining. Hope that's ok.