Skip to content
Snippets Groups Projects
Commit 6a1f34a0 authored by Bjarke Madsen's avatar Bjarke Madsen
Browse files

make region a lookup dict

parent a78ef6c1
Branches
Tags
No related merge requests found
...@@ -436,8 +436,4 @@ def get_nren_regions(host): ...@@ -436,8 +436,4 @@ def get_nren_regions(host):
data = [] data = []
jsonschema.validate(data, NREN_REGION_LIST_SCHEMA) jsonschema.validate(data, NREN_REGION_LIST_SCHEMA)
# ugly hack: if a region isn't on the list of recognised regions, prune it from the region list return {region['nren']: region['region'].upper() for region in data}
# TODO: figure out something that isn't this
recognised_regions = ['EAP']
data = [d for d in data if d['region'] in recognised_regions]
return data
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment