<filename>video_repository_api/records/indexer.py<gh_stars>0
# -*- coding: utf-8 -*-
#
# Copyright (C) 2020 CERN.
#
# OARepo Micro API is free software; you can redistribute it and/or modify it under
# the terms of the MIT License; see LICENSE file for more details.

"""Indexer for OARepo Micro API."""


def indexer_receiver(sender, arguments=None, json=None, record=None,
                     index=None, doc_type=None):
    """Move _files key to files."""
    if '_files' in json:
        json['files'] = json['_files']
        del json['_files']

<filename>video_repository_api/records/indexer.py<gh_stars>0
# -*- coding: utf-8 -*-
#
# Copyright (C) 2020 CERN.
#
# OARepo Micro API is free software; you can redistribute it and/or modify it under
# the terms of the MIT License; see LICENSE file for more details.

"""Indexer for OARepo Micro API."""


def indexer_receiver(sender, arguments=None, json=None, record=None,
                     index=None, doc_type=None):
    """Move _files key to files."""
    if '_files' in json:
        json['files'] = json['_files']
        del json['_files']

# -*- coding: utf-8 -*- # # Copyright (C) 2020 CERN. # # OARepo Micro API is free software; you can redistribute it and/or modify it under # the terms of the MIT License; see LICENSE file for more details. Indexer for OARepo Micro API. Move _files key to files.