def get_drupal_field_list(db_obj, db_cur, entity_type, bundle):

    """
    Get the names of all fields in a specified Drupal entity.

    Returns None on error, an empty array if there are no results, or
    an array of field name strings.

    Parameters:
        db_obj: the database connection object to use
        db_cur: the database cursor object to use
        entity_type: the type (e.g., 'node') of the entity to check
        bundle: the bundle (e.g., node content type) of the entity to
                check

    """

    # query string and arguments
    query_str = (
'''
SELECT fci.field_name
FROM field_config_instance as fci
LEFT JOIN field_config as fc
ON fc.id = fci.field_id
WHERE fci.entity_type = %s
AND fci.bundle = %s
AND fc.deleted = 0
'''
    )
    query_args = [entity_type, bundle]

    # execute the query
    if not db_obj.execute(db_cur, query_str.strip(), query_args,
                          has_results=True):
        return None
    ret = db_obj.fetchall(db_cur)
    if not ret[0]:
        return None
    if not ret[1]:
        return []

    return [x[0][6:] for x in ret[1] if x[0].startswith('field_')]