Fix registration available tag

Check that the user has a linked attendee before
trying to check if they have completed registration.
This commit is contained in:
Joel Addison 2024-08-19 22:57:28 +10:00
parent a43eaced80
commit 0bd1417f04

View file

@ -29,7 +29,7 @@ def registration_available(context):
# Staff can always see registration - not necessarily all parts.
return True
if user.attendee.completed_registration:
if hasattr(user, "attendee") and user.attendee.completed_registration:
# Always show to someone who has completed registration already.
return True