Add more characters to white space check
https://redd.it/y3nbdr Related Unicode characters with property White_Space=no in https://en.wikipedia.org/wiki/Whitespace_character#Unicode
This commit is contained in:
parent
33dd6c98c7
commit
a4519a1089
|
@ -101,6 +101,12 @@ def title_or_shortlink(submission):
|
|||
'\u202F', # narrow no-break space
|
||||
'\u205F', # medium mathematical space
|
||||
'\u3000', # ideographic space
|
||||
'\u180E', # mongolian vowel separator
|
||||
'\u200B', # zero width space
|
||||
'\u200C', # zero width non-joiner
|
||||
'\u200D', # zero width joiner
|
||||
'\u2060', # word joiner
|
||||
'\uFEFF', # zero width non-breaking space
|
||||
)))
|
||||
return f'<a href="{submission.shortlink}">{html.escape(title)}</a>' if title else submission.shortlink
|
||||
|
||||
|
|
Loading…
Reference in New Issue