<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def parse_primary_types(self, request):
 """ Return primary event types that occurrences must belong to, or `None` if there is no constraint on primary type. """

        if request.GET.getlist('primary_types'):
            return EventType.objects.get(
                slug__in=request.GET.getlist('primary_types'))
        return None