added delete_index option