Skip to content

Commit

Permalink
QuickDic6: Reader: unescape unicode &#x... codes in definition
Browse files Browse the repository at this point in the history
  • Loading branch information
ilius committed Nov 3, 2024
1 parent 644b62c commit c63c492
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pyglossary/plugins/quickdic6.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@

from pyglossary.core import log
from pyglossary.flags import NEVER
from pyglossary.html_utils import unescape_unicode
from pyglossary.langs import langDict
from pyglossary.option import (
Option,
Expand Down Expand Up @@ -803,7 +804,8 @@ def __iter__(self) -> typing.Iterator[EntryType]:
for idx, (_, word, defi) in enumerate(self._dic.htmls):
syns = self._synonyms.get((4, idx), set())
l_word = [word] + sorted(syns.difference({word}))
yield self._glos.newEntry(l_word, defi, defiFormat="h")
defi_new = unescape_unicode(defi)
yield self._glos.newEntry(l_word, defi_new, defiFormat="h")


class Writer:
Expand Down

0 comments on commit c63c492

Please sign in to comment.