mail: don't crash on undefined mail external id (#27616)

This commit is contained in:
Frédéric Péters 2018-10-28 08:36:22 +01:00
parent b289e9cd91
commit d0a602e0b5
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ class AppConfig(django.apps.AppConfig):
if not instance.formdata_id:
return
source = instance.source
if not hasattr(source, 'external_id'):
if not getattr(source, 'external_id', None):
return
external_id = source.external_id
if not external_id.startswith('maarch-'):