From 9d85ae3d9cbe6d4e4760d899d79a68e7569791f6 Mon Sep 17 00:00:00 2001 From: njkim Date: Tue, 24 Oct 2023 23:05:27 -0700 Subject: [PATCH] nit, #10186 --- arches/app/etl_modules/bulk_data_deletion.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/arches/app/etl_modules/bulk_data_deletion.py b/arches/app/etl_modules/bulk_data_deletion.py index d28895b953c..b1ddfcbd94f 100644 --- a/arches/app/etl_modules/bulk_data_deletion.py +++ b/arches/app/etl_modules/bulk_data_deletion.py @@ -38,19 +38,20 @@ def get_number_of_deletions(self, graph_id, nodegroup_id, resourceids): WHERE graphid = %(graph_id)s; """ + number_of_tiles = 0 if nodegroup_id: with connection.cursor() as cursor: cursor.execute(tile_deletion_count, params) row = cursor.fetchone() - print(row) number_of_resource, number_of_tiles = row - elif not resourceids: + elif resourceids: + number_of_resource = len(resourceids) + else: with connection.cursor() as cursor: cursor.execute(resource_deletion_count, params) row = cursor.fetchone() number_of_resource, = row - number_of_tiles = 0 return number_of_resource, number_of_tiles