Trey T b75b6542d9 Make detectMaxPage thread-scoped to avoid sidebar false positives
The previous fallback scanned for any anchor whose text was a number, which
matched widget elements (online count, trending threads, etc.) and inflated
the page count — a sidebar showing "26" caused detectMaxPage to report 26
pages on threads that were actually 12 and 8 pages long.

Now we derive the thread's URL prefix from the input baseUrl and only count
page-N references in hrefs that match that thread, ignoring sidebar
references to unrelated threads. The bare numeric-anchor scan is dropped.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-29 19:57:26 -05:00
S
Description
No description provided
418 KiB
Languages
JavaScript 96.9%
Python 2.1%
Shell 0.6%
CSS 0.2%
Dockerfile 0.1%