Allow full description if there is no room to shorten

This commit is contained in:
fzzyyti 2021-08-15 07:16:15 +00:00
parent ecbf2b66d2
commit 0fd31970ef
1 changed files with 4 additions and 1 deletions

View File

@ -74,7 +74,10 @@ def print_category_details(view_cat):
for link in category_details:
link_count += 1
thread_index[link_count] = link["postid"]
desc = textwrap.shorten(link["description"], width=desclen, placeholder="...")
if(desclen > 0):
desc = textwrap.shorten(link["description"], width=desclen, placeholder="...")
else:
desc = link["description"]
newmarker = (
"*" if link["last_modified_timestamp"] >= config.USER.lastlogin else ""
)