forked from rDrama/rDrama
fdfd
parent
e29a02bf11
commit
353b4679d0
|
@ -42,7 +42,7 @@ _allowed_tags = tags = ['b',
|
||||||
'span',
|
'span',
|
||||||
]
|
]
|
||||||
|
|
||||||
noimages = tags = ['b',
|
no_images = ['b',
|
||||||
'blockquote',
|
'blockquote',
|
||||||
'br',
|
'br',
|
||||||
'code',
|
'code',
|
||||||
|
@ -125,7 +125,7 @@ def sanitize(sanitized, noimages=False):
|
||||||
sanitized = sanitized.replace(i.group(1), i.group(2) + "_d." + i.group(3) + "?maxwidth=9999")
|
sanitized = sanitized.replace(i.group(1), i.group(2) + "_d." + i.group(3) + "?maxwidth=9999")
|
||||||
|
|
||||||
if noimages:
|
if noimages:
|
||||||
sanitized = bleach.Cleaner(tags=noimages,
|
sanitized = bleach.Cleaner(tags=no_images,
|
||||||
attributes=_allowed_attributes,
|
attributes=_allowed_attributes,
|
||||||
protocols=_allowed_protocols,
|
protocols=_allowed_protocols,
|
||||||
styles=_allowed_styles,
|
styles=_allowed_styles,
|
||||||
|
|
Loading…
Reference in New Issue