Add limit checking in messages

Signed-off-by: Ari Archer <ari.web.xyz@gmail.com>
This commit is contained in:
Ari Archer 2022-07-15 01:08:12 +03:00
parent f77a1a040c
commit 7bfc8afc6d
Signed by untrusted user who does not match committer: ari
GPG key ID: A50D5B4B599AF8A2

View file

@ -555,7 +555,7 @@ class MessageParser:
@classmethod
def type_chat(cls, content: List[str]) -> Tuple[str]:
if len(content) > 3 or not content[0].strip():
if len(content) > 3 or len(" ".join(content[1:])) > 78 or not content[0].strip():
return cls.type_nop(content)
user: str = content[0]