codebase: Truncate subjects to 60 characters
(imported from commit db5ba1a8af80f2060aec03b3ba1d9e0f3e75c0b3)
This commit is contained in:
parent
b26c47ee5e
commit
dac447d14e
|
@ -220,6 +220,9 @@ def handle_event(event):
|
||||||
logging.info("Unknown event type %s, ignoring!" % (event_type,))
|
logging.info("Unknown event type %s, ignoring!" % (event_type,))
|
||||||
|
|
||||||
if subject and content:
|
if subject and content:
|
||||||
|
if len(subject) > 60:
|
||||||
|
subject = subject[:57].rstrip() + '...'
|
||||||
|
|
||||||
res = client.send_message({"type": "stream",
|
res = client.send_message({"type": "stream",
|
||||||
"to": stream,
|
"to": stream,
|
||||||
"subject": subject,
|
"subject": subject,
|
||||||
|
|
Loading…
Reference in a new issue