remove excess lines from non-embed notifications
This commit is contained in:
parent
c507bafa87
commit
0187890dc1
1 changed files with 2 additions and 2 deletions
|
@ -73,13 +73,13 @@ async def handle_notification(db_updates, ctx, message, keyword, user_id, use_em
|
||||||
log.debug("Sending plain message")
|
log.debug("Sending plain message")
|
||||||
paginator = Paginator(prefix="", suffix="")
|
paginator = Paginator(prefix="", suffix="")
|
||||||
paginator.add_line(header)
|
paginator.add_line(header)
|
||||||
paginator.add_line(empty=True)
|
paginator.add_line()
|
||||||
for line in indent(message.content, "> ", lambda line: True).strip().split("\n"):
|
for line in indent(message.content, "> ", lambda line: True).strip().split("\n"):
|
||||||
if len(line) < 1990:
|
if len(line) < 1990:
|
||||||
paginator.add_line(line)
|
paginator.add_line(line)
|
||||||
else:
|
else:
|
||||||
paginator.add_line(line[:1975] + " (... Line too long)")
|
paginator.add_line(line[:1975] + " (... Line too long)")
|
||||||
paginator.add_line(empty=True)
|
paginator.add_line()
|
||||||
paginator.add_line(footer)
|
paginator.add_line(footer)
|
||||||
try:
|
try:
|
||||||
for page in paginator.pages:
|
for page in paginator.pages:
|
||||||
|
|
Loading…
Reference in a new issue