Fix #1016
This commit is contained in:
parent
7e530618b7
commit
f543d7f486
|
@ -100,8 +100,10 @@ def create_app():
|
||||||
|
|
||||||
if services.ldap:
|
if services.ldap:
|
||||||
services.ldap.init_app(app, config)
|
services.ldap.init_app(app, config)
|
||||||
if services.goodreads:
|
if services.goodreads_support:
|
||||||
services.goodreads.connect(config.config_goodreads_api_key, config.config_goodreads_api_secret, config.config_use_goodreads)
|
services.goodreads_support.connect(config.config_goodreads_api_key,
|
||||||
|
config.config_goodreads_api_secret,
|
||||||
|
config.config_use_goodreads)
|
||||||
|
|
||||||
return app
|
return app
|
||||||
|
|
||||||
|
|
|
@ -63,7 +63,7 @@ _VERSIONS = OrderedDict(
|
||||||
pytz=pytz.__version__,
|
pytz=pytz.__version__,
|
||||||
Unidecode = unidecode_version,
|
Unidecode = unidecode_version,
|
||||||
Flask_SimpleLDAP = _(u'installed') if bool(services.ldap) else _(u'not installed'),
|
Flask_SimpleLDAP = _(u'installed') if bool(services.ldap) else _(u'not installed'),
|
||||||
Goodreads = _(u'installed') if bool(services.goodreads) else _(u'not installed'),
|
Goodreads = _(u'installed') if bool(services.goodreads_support) else _(u'not installed'),
|
||||||
)
|
)
|
||||||
_VERSIONS.update(uploader.get_versions())
|
_VERSIONS.update(uploader.get_versions())
|
||||||
|
|
||||||
|
|
|
@ -46,7 +46,7 @@ from .web import admin_required, render_title_template, before_request, unconfig
|
||||||
|
|
||||||
feature_support = {
|
feature_support = {
|
||||||
'ldap': False, # bool(services.ldap),
|
'ldap': False, # bool(services.ldap),
|
||||||
'goodreads': bool(services.goodreads)
|
'goodreads': bool(services.goodreads_support)
|
||||||
}
|
}
|
||||||
|
|
||||||
# try:
|
# try:
|
||||||
|
@ -338,8 +338,10 @@ def _configuration_update_helper():
|
||||||
_config_checkbox("config_use_goodreads")
|
_config_checkbox("config_use_goodreads")
|
||||||
_config_string("config_goodreads_api_key")
|
_config_string("config_goodreads_api_key")
|
||||||
_config_string("config_goodreads_api_secret")
|
_config_string("config_goodreads_api_secret")
|
||||||
if services.goodreads:
|
if services.goodreads_support:
|
||||||
services.goodreads.connect(config.config_goodreads_api_key, config.config_goodreads_api_secret, config.config_use_goodreads)
|
services.goodreads_support.connect(config.config_goodreads_api_key,
|
||||||
|
config.config_goodreads_api_secret,
|
||||||
|
config.config_use_goodreads)
|
||||||
|
|
||||||
_config_int("config_updatechannel")
|
_config_int("config_updatechannel")
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ from .. import logger
|
||||||
log = logger.create()
|
log = logger.create()
|
||||||
|
|
||||||
|
|
||||||
try: from . import goodreads
|
try: from . import goodreads_support
|
||||||
except ImportError as err:
|
except ImportError as err:
|
||||||
log.debug("cannot import goodreads, showing authors-metadata will not work: %s", err)
|
log.debug("cannot import goodreads, showing authors-metadata will not work: %s", err)
|
||||||
goodreads = None
|
goodreads = None
|
||||||
|
|
|
@ -55,7 +55,7 @@ from .redirect import redirect_back
|
||||||
|
|
||||||
feature_support = {
|
feature_support = {
|
||||||
'ldap': False, # bool(services.ldap),
|
'ldap': False, # bool(services.ldap),
|
||||||
'goodreads': bool(services.goodreads)
|
'goodreads': bool(services.goodreads_support)
|
||||||
}
|
}
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user