remotes/1693045480750635534/spooky-22
Aevann1 2021-08-13 02:58:41 +02:00
parent e54b509031
commit aa78c6d8a5
1 changed files with 3 additions and 3 deletions

View File

@ -180,9 +180,9 @@ def sanitize(text, linkgen=False, flair=False):
if flair: emojisize = 20
else: emojisize = 30
for i in re.finditer(':(.{1,30}?):</p>', sanitized):
if path.isfile(f'./files/assets/images/emojis/{i.group(1)}.gif'):
sanitized = sanitized.replace(f':{i.group(1)}:', f'<img data-toggle="tooltip" title="{i.group(1)}" delay="0" height={emojisize} src="https://{site}/assets/images/emojis/{i.group(1)}.gif"<span>')
# for i in re.finditer(':(.{1,30}?):</p>', sanitized):
# if path.isfile(f'./files/assets/images/emojis/{i.group(1)}.gif'):
# sanitized = sanitized.replace(f':{i.group(1)}:', f'<img data-toggle="tooltip" title="{i.group(1)}" delay="0" height={emojisize} src="https://{site}/assets/images/emojis/{i.group(1)}.gif"<span>')
for i in re.finditer(':(.{1,30}?):', sanitized):
if path.isfile(f'./files/assets/images/emojis/{i.group(1)}.gif'):
sanitized = sanitized.replace(f':{i.group(1)}:', f'<img data-toggle="tooltip" title="{i.group(1)}" delay="0" height={emojisize} src="https://{site}/assets/images/emojis/{i.group(1)}.gif"<span>')