Skip to content

Commit b07d1c4

Browse files
committed
Fix unicode
1 parent 804fc31 commit b07d1c4

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎language_tool_python/match.py‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import unicodedata
12
from collections import OrderedDict
23
from functools import total_ordering
34

@@ -56,6 +57,8 @@ def __init__(self, attrib):
5657
attrib['replacements'] = [r['value'] for r in attrib['replacements']]
5758
# Rename error length.
5859
attrib['errorLength'] = attrib['length']
60+
# Normalize unicode
61+
attrib['message'] = unicodedata.normalize("NFKC", attrib['message'])
5962
# Store objects on self.
6063
for k, v in attrib.items():
6164
setattr(self, k, v)

0 commit comments

Comments
 (0)