data: fix path computations

This commit is contained in:
Benjamin Dauvergne 2017-02-28 12:03:15 +01:00
parent b7a7dbedc6
commit c260e51847
1 changed files with 2 additions and 2 deletions

View File

@ -45,8 +45,8 @@ class CommonSchema(models.Model):
subschema = schema['properties'][key]
t = subschema.get('type')
if t == 'object':
paths.extend(([key] + subpath, _type)
for subpath, _type in self.paths(subschema))
paths.extend(([key] + subpath, _type, _format)
for subpath, _type, _format in self.paths(subschema))
elif t is not None:
paths.append(([key], t, subschema.get('format')))
return paths