Fix importing error

This commit is contained in:
Takeshi KOMIYA 2016-07-08 00:14:13 +09:00
parent a37106599c
commit 593708a39c

View File

@ -13,7 +13,6 @@ import codecs
import posixpath
from docutils.utils import relative_path
from sphinx.util.osutil import copyfile, ensuredir, walk
from sphinx.util.template import SphinxRenderer
def copy_asset_file(source, destination, context=None, renderer=None):
@ -36,6 +35,7 @@ def copy_asset_file(source, destination, context=None, renderer=None):
if source.lower().endswith('_t') and context:
if renderer is None:
from sphinx.util.template import SphinxRenderer
renderer = SphinxRenderer()
with codecs.open(source, 'r', encoding='utf-8') as fsrc: