From e11f19f8f5226451c510ca262caa4d46b6e4f6fb Mon Sep 17 00:00:00 2001 From: Jorran de Wit <jorrandewit@outlook.com> Date: Mon, 5 Nov 2018 11:52:35 +0100 Subject: [PATCH] Fix 1243784395 --- profiles/forms.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/profiles/forms.py b/profiles/forms.py index 53e822cd3..f70fea70a 100644 --- a/profiles/forms.py +++ b/profiles/forms.py @@ -111,7 +111,8 @@ class ProfileMergeForm(forms.Form): profile_old = self.cleaned_data['to_merge'] # Merge scientific information from old Profile to the new Profile. - profile.expertises += list(set(profile_old.expertises) - set(profile.expertises)) + profile.expertises = list( + set(profile_old.expertises or []) | set(profile.expertises or [])) if profile.orcid_id is None: profile.orcid_id = profile_old.orcid_id if profile.webpage is None: -- GitLab