mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
Fix SUMMARY_MAX_PARAGRAPHS with SUMMARY_MAX_LENGTH
When, for example, the content is 2 paragraphs, each consisting of 30 words, and SUMMARY_MAX_PARAGRAPHS=1 and SUMMARY_MAX_LENGTH=50, the current behavior produces a summary with 50 words and 2 paragraphs, effectively ignoring SUMMARY_MAX_PARAGRAPHS. This change inverts this behavior: the resulting summary from the above situation will consist of the entire first 30 word paragraph. In the case where the first paragraph(s) is longer than SUMMARY_MAX_LENGTH, the summary will still be truncated to that length. This change brings the actual behavior in line with the documented behavior.
This commit is contained in:
parent
882cd16e11
commit
4c36dafaf6
3 changed files with 30 additions and 5 deletions
3
RELEASE.md
Normal file
3
RELEASE.md
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
Release type: patch
|
||||
|
||||
Fix SUMMARY_MAX_PARAGRAPHS not being respected in some combinations with SUMMARY_MAX_LENGTH.
|
||||
Loading…
Add table
Add a link
Reference in a new issue