From ee65922ce6a69af9c229b7d10748c08d1f75bbf6 Mon Sep 17 00:00:00 2001 From: Evildoor Date: Tue, 28 May 2019 11:16:56 +0200 Subject: [PATCH] Simplify a field retrieval. --- Utils/Dataflow/071_esConsistency/consistency.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Utils/Dataflow/071_esConsistency/consistency.py b/Utils/Dataflow/071_esConsistency/consistency.py index cf4c92d28..68a604d21 100755 --- a/Utils/Dataflow/071_esConsistency/consistency.py +++ b/Utils/Dataflow/071_esConsistency/consistency.py @@ -151,9 +151,7 @@ def process(stage, message): log('Insufficient ES info in data:' + str(data), 'WARN') return False - _parent = None - if '_parent' in data: - _parent = data.pop('_parent') + _parent = data.pop('_parent', None) # Crutch. Remove unwanted (for now) fields added by Stage 016. for field in ['phys_category', 'chain_data', 'chain_id']: