Skip to content

Commit

Permalink
fix(core): Ensure API v1 Ticket sets the ticket type prior to validation
Browse files Browse the repository at this point in the history
  • Loading branch information
jon-nfc committed Nov 27, 2024
1 parent 6668c6a commit 56dd268
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/api/serializers/core/ticket.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,10 @@ def is_valid(self, *, raise_exception=True) -> bool:

self._ticket_type = str(self.fields['ticket_type'].choices[self._context['view']._ticket_type_value]).lower().replace(' ', '_')

is_valid = self.validate_ticket()

self.validated_data['ticket_type'] = int(self._context['view']._ticket_type_value)

is_valid = self.validate_ticket()

if self.instance is None:

subscribed_users: list = []
Expand Down

0 comments on commit 56dd268

Please sign in to comment.