1
0
Fork 0
mirror of https://github.com/seanmorley15/AdventureLog.git synced 2025-08-05 13:15:18 +02:00

Merge pull request #557 from lkiesow/python-syntax-error

Fix Python Syntax Error
This commit is contained in:
Sean Morley 2025-04-14 11:11:48 -04:00 committed by GitHub
commit 988cdc12e6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -23,6 +23,7 @@ class CollectionViewSet(viewsets.ModelViewSet):
order_direction = self.request.query_params.get('order_direction', 'asc')
valid_order_by = ['name', 'updated_at', 'start_date']
if order_by not in valid_order_by:
order_by = 'updated_at'
if order_direction not in ['asc', 'desc']: