diff --git a/rowers/forms.py b/rowers/forms.py index 290e5f00..65122682 100644 --- a/rowers/forms.py +++ b/rowers/forms.py @@ -892,8 +892,11 @@ class RaceResultFilterForm(forms.Form): self.fields['boatclass'].choices = boatclasschoices # boattype - theboattypees = [record.boattype for record in records] - theboattypees = list(set(theboattypees)) + try: + theboattypees = [record.boattype for record in records] + theboattypees = list(set(theboattypees)) + except AttributeError: + theboattypees = [] if len(theboattypees)<= 1: del self.fields['boattype']