fix: limit max length for cards (#22289)

This commit is contained in:
Shivam Mishra 2020-06-17 13:18:15 +00:00 committed by GitHub
parent dec17d5ce4
commit 64d772480b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -49,8 +49,8 @@ def get_favorite_articles(favorite_articles):
favorite_article_list=[]
for article in favorite_articles:
description = frappe.utils.strip_html(article.content)
if len(description) > 175:
description = description[:172] + '...'
if len(description) > 120:
description = description[:120] + '...'
favorite_article_dict = {
'title': article.title,
'description': description,