Skip to content

Commit

Permalink
Fix validations
Browse files Browse the repository at this point in the history
  • Loading branch information
ferblape committed Nov 21, 2024
1 parent 77dd836 commit 277d2f8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/section_extractor/toc.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ def valid_toc_item?(toc_item)
when :numeric
match = toc_item.raw_title.match(/^(\d+)/)
match.size > 0 && match[1].to_i <= MAX_NUMERIC_TOC_ITEM
else
true
end
end
end
Expand Down

0 comments on commit 277d2f8

Please sign in to comment.