mirror of
https://github.com/gryf/ebook-converter.git
synced 2026-03-09 19:15:46 +01:00
Moved replace_entities to utils.entities.
This commit is contained in:
@@ -29,11 +29,6 @@ class CurrentDir(object):
|
||||
_ent_pat = re.compile(r'&(\S+?);')
|
||||
|
||||
|
||||
def replace_entities(raw, encoding='cp1252'):
|
||||
return _ent_pat.sub(partial(entities.entity_to_unicode, encoding=encoding),
|
||||
raw)
|
||||
|
||||
|
||||
def xml_replace_entities(raw, encoding='cp1252'):
|
||||
return _ent_pat.sub(partial(entities.xml_entity_to_unicode,
|
||||
encoding=encoding), raw)
|
||||
|
||||
Reference in New Issue
Block a user