def del_inline_form_field(inline_form, old_entries, field_name):
    """
    Delete a field from an inline form
    :param inline_form: the inline form from which the field will be deleted
    :param old_entries: Existing lines of the inline form
    :param field_name:  Name of the field to be deleted
    :return: None
    """
    if hasattr(inline_form, field_name):
        delattr(inline_form, field_name)
    for entry in old_entries:
        if hasattr(entry.form, field_name):
            delattr(entry.form, field_name)
        if hasattr(entry.form._fields, field_name):
            delattr(entry.form._fields, field_name)
