def to_data(self, data): """converts metadata obj to type dict""" if 'Metadata' in str(type(data)): return Metadata._obj_to_dict(data)