Fix to use registry.load_extension() instead

This commit is contained in:
Takeshi KOMIYA committed 2017-04-23 17:11:01 +09:00
1 parent 3a0f7d3bad
commit 10585c5283
1 file changed
+1 -2
+1 -2
View File
@@ -23,7 +23,6 @@ from six.moves import configparser
from sphinx import package_dir
from sphinx.deprecation import RemovedInSphinx20Warning
from sphinx.errors import ThemeError
from sphinx.extension import load_extension
from sphinx.locale import _
from sphinx.util import logging
from sphinx.util.osutil import ensuredir
@@ -224,7 +223,7 @@ class HTMLThemeFactory(object):
entry_points = pkg_resources.iter_entry_points('sphinx.html_themes', name)
try:
entry_point = next(entry_points)
load_extension(self.app, entry_point.module_name)
self.app.registry.load_extension(self.app, entry_point.module_name)
return
except StopIteration:
pass