Fix error on titles 256 characters, closes #147

This commit is contained in:
Zeva Rose 2022-06-10 12:30:24 -06:00
parent f0c2e51692
commit 51ec866647

View file

@ -54,7 +54,9 @@ class RedditCog(Extension):
author_url = f"https://reddit.com/u/{post.author.name}"
author_icon = post.author.icon_img
images = []
title = f"{post.title}"
title = post.title
if len(title) > 256:
title = title[253] + "..."
fields = []
content = ""
og_post = None