pull/3747/head
johnnylau 2 years ago
parent 62621ce18c
commit a3abecac47
No known key found for this signature in database
GPG Key ID: 51660AB66999DC62

@ -210,9 +210,11 @@ def to_string(value):
return ", ".join(map(str, value))
return str(value)
def remove_invisible_chars_strip(text):
"""Remove all invisible characters from 'text' then strip"""
return "".join(c for c in text if unicodedata.category(c)[0] != "C").strip()
return "".join(c for c in text if unicodedata.category(c)[0] != "C")\
.strip()
def datetime_to_timestamp(dt):

Loading…
Cancel
Save