no need to check speakers type as they are always a list

Closes #3883
This commit is contained in:
Serghei Mihai 2013-11-15 14:50:38 +01:00
parent adf7cd9d71
commit 15aa5d0286
No known key found for this signature in database
GPG Key ID: 76D1C964BF2FA1AF
1 changed files with 1 additions and 8 deletions

View File

@ -249,14 +249,7 @@ class SyncFromThemis(UtilityView):
'orateurs_en_seanceprop', 'orateurs_rapportcom',
'orateurs_seance_reponse_orale'):
if data.get(attr):
speakers = data.get(attr)
# check if the speakers is a list, which is not a case if
# the field is of type 'Ministry or Deputy'
if isinstance(speakers, list):
object.speakers = list(set(object.speakers + speakers))
else:
if speakers not in object.speakers:
object.speakers.append(speakers)
object.speakers = list(set(object.speakers + data.get(attr)))
if data.get('rapporteurs'):
object.reporters = data.get(attr)