Skip to content
Snippets Groups Projects
Commit 5ef6a29d authored by Duncan Meacher's avatar Duncan Meacher
Browse files

Merge branch 'fix-api-config' into 'master'

Fix incompatibility between !29 and !31

See merge request !32
parents 99f54fd8 b5436ade
No related branches found
No related tags found
1 merge request!32Fix incompatibility between !29 and !31
Pipeline #367980 passed
......@@ -32,7 +32,7 @@ blueprint = Blueprint(
@authentication.validate
@as_json
def version():
supported_apis = current_app.config["LDRDataFindServer"]["supported_apis"]
supported_apis = current_app.config["supported_apis"]
return {
"version": VERSION,
"api_versions": supported_apis,
......
......@@ -91,7 +91,7 @@ class GWDataFindApp(Flask):
self.register_blueprint(base_api.blueprint)
# register all supported APIs
supported_apis = self.config["LDRDataFindServer"].get(
supported_apis = self.config.get(
"supported_apis",
[DEFAULT_API],
)
......@@ -102,7 +102,7 @@ class GWDataFindApp(Flask):
self.register_blueprint(api_mod.blueprint)
# store the formatted list to be used by the /api/version endpoint
self.config["LDRDataFindServer"]["supported_apis"] = supported_apis
self.config["supported_apis"] = supported_apis
def _get_cache_data(self, keys):
cache = self.cache_manager.cache
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment