config: support omitting the excluded routes
This commit is contained in:
parent
e1753f26cb
commit
be4c6cdeb8
|
@ -27,7 +27,10 @@ def load_config():
|
||||||
host['repl_decoded'] = host['repl']
|
host['repl_decoded'] = host['repl']
|
||||||
host['repl'] = host['repl'].encode()
|
host['repl'] = host['repl'].encode()
|
||||||
host['mime_types'] = frozenset(host.get('mime_types', ()))
|
host['mime_types'] = frozenset(host.get('mime_types', ()))
|
||||||
host['excluded_routes'].sort(key=len, reverse=True)
|
try:
|
||||||
|
host['excluded_routes'].sort(key=len, reverse=True)
|
||||||
|
except KeyError:
|
||||||
|
host['excluded_routes'] = ()
|
||||||
|
|
||||||
return config
|
return config
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue