def remove_es_keys(hit):
    """
    Removes ES keys from a hit object in-place

    Args:
        hit (dict): Elasticsearch hit object

    Returns:
        dict: modified Elasticsearch hit object
    """
    del hit['_id']
    if '_type' in hit:
        del hit['_type']
    return hit