Skip to content

Commit

Permalink
linting
Browse files Browse the repository at this point in the history
  • Loading branch information
malcolmm20 committed Mar 21, 2024
1 parent eb6ac1e commit 2f2dbb4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions backend/auction/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,8 @@ def post(self, request, *args, **kwargs):
{"message": "Vehicle added to auction successfully"},
status=status.HTTP_201_CREATED,
)



class AuctionVehiclesApiView(APIView):
"""
An endpoint to retrieve an auction's associated vehicles
Expand All @@ -225,7 +226,7 @@ def get(self, request, **kwargs):
auction = get_object_or_404(Auction, id=auction_id)

auction_items = AuctionItem.objects.filter(auction_id=auction)

vehicle_list = []
equipment_list = []
trailer_list = []
Expand All @@ -241,7 +242,6 @@ def get(self, request, **kwargs):
vehicle_data = [{"id": vehicle.id} for vehicle in vehicle_list]
equipment_data = [{"id": equipment.id} for equipment in equipment_list]
trailer_data = [{"id": trailer.id} for trailer in trailer_list]

return Response({"vehicles": vehicle_data, "equipment": equipment_data,
"trailers": trailer_data}, status=status.HTTP_200_OK)

return Response({"vehicles": vehicle_data, "equipment": equipment_data,
"trailers": trailer_data}, status=status.HTTP_200_OK)

0 comments on commit 2f2dbb4

Please sign in to comment.