def currentEvent(self):
        '''
        Return the first event that hasn't ended yet, or if there are no
        future events, the last one to end.
        '''
        currentEvent =  self.recentEvents.filter(endTime__gte=timezone.now()).order_by('startTime').first()
        if not currentEvent:
            currentEvent = self.recentEvents.filter(
                endTime__lte=timezone.now()
            ).order_by('-endTime').first()
        return currentEvent
def currentEvent ( self ) : currentEvent = self . recentEvents . filter ( endTime__gte = timezone . now ( ) ) . order_by ( 'startTime' ) . first ( ) if not currentEvent : currentEvent = self . recentEvents . filter ( endTime__lte = timezone . now ( ) ) . order_by ( '-endTime' ) . first ( ) return currentEvent
Return the first event that hasn't ended yet, or if there are no
        future events, the last one to end.