|
|
@ -1108,7 +1108,10 @@ def metadata_encoder(metadata):
|
|
|
|
metadata_new = []
|
|
|
|
metadata_new = []
|
|
|
|
for key in metadata:
|
|
|
|
for key in metadata:
|
|
|
|
value = metadata[key]
|
|
|
|
value = metadata[key]
|
|
|
|
metadata_new.append({key: value})
|
|
|
|
metadata_new.append({
|
|
|
|
|
|
|
|
"key": key,
|
|
|
|
|
|
|
|
"value": value
|
|
|
|
|
|
|
|
})
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
'items': metadata_new
|
|
|
|
'items': metadata_new
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -1120,7 +1123,7 @@ def metadata_decoder(metadata):
|
|
|
|
if 'items' in metadata:
|
|
|
|
if 'items' in metadata:
|
|
|
|
metadata_items = metadata['items']
|
|
|
|
metadata_items = metadata['items']
|
|
|
|
for item in metadata_items:
|
|
|
|
for item in metadata_items:
|
|
|
|
items[item.keys()[0]] = item[item.keys()[0]]
|
|
|
|
items[item['key']] = item['value']
|
|
|
|
return items
|
|
|
|
return items
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|