From 2cb2a4a434dec8dcd61961cc64121b6c64671913 Mon Sep 17 00:00:00 2001 From: Sourcery AI <> Date: Fri, 2 Apr 2021 10:31:21 +0000 Subject: [PATCH] 'Refactored by Sourcery' --- gendiff/comparator.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/gendiff/comparator.py b/gendiff/comparator.py index efa2dea..1266343 100644 --- a/gendiff/comparator.py +++ b/gendiff/comparator.py @@ -16,12 +16,10 @@ def compose_diff(first_data_set, second_data_set): - diff = {} keys_matched = first_data_set.keys() & second_data_set.keys() - for key in keys_matched: - diff[key] = compare_keys_matched( + diff = {key: compare_keys_matched( first_data_set[key], second_data_set[key], - ) + ) for key in keys_matched} keys_removed = first_data_set.keys() - second_data_set.keys() for key in keys_removed: # noqa:WPS440 diff[key] = {STATUS: REMOVED, VALUE: first_data_set[key]} # noqa:WPS441, E501