mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2025-12-24 20:42:43 +00:00
Remove page + 1 from ToC generator snippet
This commit is contained in:
@@ -8,14 +8,14 @@ const getTOC = (pages)=>{
|
||||
if(curDepth == targetDepth) {
|
||||
child.push({
|
||||
title : title,
|
||||
page : page + 1,
|
||||
page : page,
|
||||
children : []
|
||||
});
|
||||
} else {
|
||||
if(child.length == 0) {
|
||||
child.push({
|
||||
title : null,
|
||||
page : page + 1,
|
||||
page : page,
|
||||
children : []
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user