better error messages if option doesn't exists
This commit is contained in:
@ -811,12 +811,16 @@ class Config:
|
||||
subpaths = path.split('.')[len(root):]
|
||||
else:
|
||||
subpaths = path.split('.')
|
||||
current_subpath = 'root'
|
||||
for subpath in subpaths:
|
||||
if root_path:
|
||||
root_path += '.' + subpath
|
||||
else:
|
||||
root_path = subpath
|
||||
schema = schema['properties'][root_path]
|
||||
schema = schema['properties'].get(root_path)
|
||||
if schema is None:
|
||||
raise AttributeError(_(f'option "{subpath}" inconnue dans l\'optiondescription "{current_subpath}"'))
|
||||
current_subpath = subpath
|
||||
return schema
|
||||
|
||||
def isleader(self,
|
||||
|
Reference in New Issue
Block a user