mirror of
https://github.com/gryf/ebook-converter.git
synced 2026-04-25 16:01:29 +02:00
Move force_uniceode to utils package
This commit is contained in:
@@ -9,9 +9,9 @@ import shutil
|
||||
from math import ceil
|
||||
|
||||
from ebook_converter import constants_old
|
||||
from ebook_converter import force_unicode
|
||||
from ebook_converter.constants_old import (filesystem_encoding,
|
||||
preferred_encoding)
|
||||
from ebook_converter.utils import encoding as uenc
|
||||
from ebook_converter.utils.localization import get_udc
|
||||
|
||||
|
||||
@@ -183,7 +183,7 @@ def case_preserving_open_file(path, mode='wb', mkdir_mode=0o777):
|
||||
|
||||
path = os.path.abspath(path)
|
||||
|
||||
sep = force_unicode(os.sep, 'ascii')
|
||||
sep = uenc.force_unicode(os.sep, 'ascii')
|
||||
|
||||
if path.endswith(sep):
|
||||
path = path[:-1]
|
||||
|
||||
Reference in New Issue
Block a user