Ignore:
Timestamp:
19 Sep 2021, 16:20:32 (3 years ago)
Author:
Henrik Bettermann
Message:

Catch AttributeError?.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/applicants/export.py

    r16621 r16626  
    4747            course_admitted = getattr(context, 'course_admitted', None)
    4848            if course_admitted is not None:
    49                 value = course_admitted.__parent__.__parent__.code
     49                try:
     50                    value = course_admitted.__parent__.__parent__.code
     51                except AttributeError:
     52                    value = 'N/A'
    5053        return super(
    5154            CustomApplicantExporter, self).mangle_value(
Note: See TracChangeset for help on using the changeset viewer.