Minor code cleanup

This commit is contained in:
udf 2018-11-21 22:13:42 +02:00
parent 5935c19387
commit e760062218
Signed by untrusted user: kate
GPG Key ID: E40724BAD73AF77B
1 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ from telethon.tl.types import MessageEntityPre
from telethon.tl.tlobject import TLObject
import datetime
PRINTABLE_SET = set(bytes(string.printable, 'ascii'))
PRINTABLE_SET = set(string.printable.encode())
STR_LEN_MAX = 256
BYTE_LEN_MAX = 64
@ -19,7 +19,7 @@ def parse_pre(text):
text = text.strip()
return (
text,
[MessageEntityPre(offset=0, length=len(add_surrogate(text)), language='potato')]
[MessageEntityPre(offset=0, length=len(add_surrogate(text)), language='')]
)