From e649489298d9c91beb239f6b2cb910e843d91676 Mon Sep 17 00:00:00 2001 From: Valentin Kuznetsov Date: Thu, 28 Jul 2022 13:55:25 -0400 Subject: [PATCH] Delete operation should delete only attributes which exists --- Server/Python/src/dbs/business/DBSBlockInsert.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Server/Python/src/dbs/business/DBSBlockInsert.py b/Server/Python/src/dbs/business/DBSBlockInsert.py index e6980905..9439ee05 100644 --- a/Server/Python/src/dbs/business/DBSBlockInsert.py +++ b/Server/Python/src/dbs/business/DBSBlockInsert.py @@ -254,8 +254,8 @@ def insertBlockFile(self, blockcontent, datasetId, migration=False): hasFparentage = True if migration: fileParentList[k]['this_file_id'] = logicalFileName[fileParentList[k]['this_logical_file_name']] - del fileParentList[k]['this_logical_file_name'] - del fileParentList[k]['parent_file_id'] + fileParentList[k].pop('this_logical_file_name', None) + fileParentList[k].pop('parent_file_id', None) else: fileParentList[k]['this_file_id'] = logicalFileName[fileParentList[k]['logical_file_name']] del fileParentList[k]['logical_file_name']