diff options
author | jeffreytse <jeffreytse.mail@gmail.com> | 2021-01-11 18:48:37 +0800 |
---|---|---|
committer | jeffreytse <jeffreytse.mail@gmail.com> | 2021-01-11 18:48:37 +0800 |
commit | d2f30259581db6e1cce903dbd2f5d1987c3c4f34 (patch) | |
tree | 4848e8c0f078984d73f5310fc9b708baa35eed27 /_includes/functions/get_article_excerpt.html | |
parent | 4be8ad5418b14cd3aeb93f7f379884edc0c55a1d (diff) |
fix: invalid integer in get_article_excerpt function
Diffstat (limited to '_includes/functions/get_article_excerpt.html')
-rw-r--r-- | _includes/functions/get_article_excerpt.html | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/_includes/functions/get_article_excerpt.html b/_includes/functions/get_article_excerpt.html index da1f914..73793fd 100644 --- a/_includes/functions/get_article_excerpt.html +++ b/_includes/functions/get_article_excerpt.html @@ -20,11 +20,13 @@ {% assign _article = article | strip_html %} {% assign _words = _article | size %} +{% assign _size = excerpt_size %} + {% if lang != "en" %} {% assign _size = words | times: 1.0 | divided_by: _words - | times: excerpt_size + | times: _size | round %} {% endif %} |