Revert term/reading string normalization due to undesirable changes (#1959)

This commit is contained in:
toasted-nutbread 2021-09-26 13:29:50 -04:00 committed by GitHub
parent 076170cc38
commit 25fe3ba514
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -587,10 +587,12 @@ class DictionaryImporter {
}
_normalizeTermOrReading(text) {
try {
return text.normalize('NFC');
} catch (e) {
return text;
}
// Note: this function should not perform String.normalize on the text,
// as it will characters in an undesirable way.
// Thus, this function is currently a no-op.
// Example:
// - '\u9038'.normalize('NFC') => '\u9038' (逸)
// - '\ufa67'.normalize('NFC') => '\u9038' (逸 => 逸)
return text;
}
}