@prose-reader/core 1.34.0 → 1.35.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -751,18 +751,18 @@
751
751
  const spineItemIsBeforeThisTocItem = spineItemIndex < spineItemIndexOfPossibleCandidate;
752
752
  if (spineItemIsBeforeThisTocItem)
753
753
  return acc;
754
- return {
755
- title: tocItem2.title,
756
- path: tocItem2.path
757
- };
758
- }
759
- const subInfo = getChapterInfo(href, tocItem2.contents, manifest);
760
- if (subInfo) {
761
- return {
762
- subChapter: subInfo,
754
+ const info = {
763
755
  title: tocItem2.title,
764
756
  path: tocItem2.path
765
757
  };
758
+ const subInfo = getChapterInfo(href, tocItem2.contents, manifest);
759
+ if (subInfo) {
760
+ return {
761
+ ...info,
762
+ subChapter: subInfo
763
+ };
764
+ }
765
+ return info;
766
766
  }
767
767
  return acc;
768
768
  }, void 0);