mirror of
https://github.com/lnbits/lnbits.git
synced 2025-04-23 06:54:27 +02:00
use isinstance, not type
This commit is contained in:
parent
c448287f4a
commit
9d27a6f272
@ -79,7 +79,7 @@ class Connection(Compat):
|
||||
CLEANR = re.compile("<.*?>|&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-f]{1,6});")
|
||||
|
||||
def cleanhtml(raw_html):
|
||||
if type(raw_html) == str:
|
||||
if isinstance(raw_html, str):
|
||||
cleantext = re.sub(CLEANR, "", raw_html)
|
||||
return cleantext
|
||||
else:
|
||||
|
Loading…
x
Reference in New Issue
Block a user