From b002898f2bf1eb39389f31d9b57b7d408f3a6865 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Wed, 20 Nov 2019 09:43:48 +0100 Subject: [PATCH] Simplify how the initialCClist is being built This makes the code for people using the same logic as the code for groups thus making it easier to read and review. Signed-off-by: Pierre-Yves Chibon --- distgit_bugzilla_sync/script.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/distgit_bugzilla_sync/script.py b/distgit_bugzilla_sync/script.py index 57337d4..e8fe81f 100644 --- a/distgit_bugzilla_sync/script.py +++ b/distgit_bugzilla_sync/script.py @@ -216,11 +216,11 @@ class BugzillaProxy: '''Add or update a component to have the values specified. ''' # Turn the cclist into something usable by bugzilla - if not cclist or 'people' not in cclist: - initialCCList = list() - else: - initialCCList = [ + initialCCList = list() + if 'people' in cclist: + user_cc = [ self._get_bugzilla_email(cc) for cc in cclist['people']] + initialCCList.extend(user_cc) if 'groups' in cclist: group_cc = [ self._get_bugzilla_email(cc) for cc in cclist['groups']]