'Turn an array of dict: filename, content into a files array'

@staticmethod
def create_tmp_files_from_contents(content, content_type=None):

    if (not isinstance(content, list)):
        content = [content]
    files = []
    for item in content:
        path = Utils.create_tmp_file_from_contents((item['path'] + '-'), item['data'], ftype=content_type)
        files.append({'name': os.path.basename(item['path']), 'path': path})
    return files
