1
0
mirror of https://github.com/fspc/workstand.git synced 2025-02-23 09:13:23 -05:00

Add failed so I know what up.

This commit is contained in:
Drew Larson 2017-05-24 08:48:04 -06:00
parent 4c5db082ab
commit 5732f4bdc6

View File

@ -50,7 +50,7 @@ class BikeViewSet(viewsets.ModelViewSet):
bike = get_object_or_404(Bike, pk=pk) bike = get_object_or_404(Bike, pk=pk)
state = BikeState.AVAILABLE state = BikeState.AVAILABLE
if not can_proceed(bike.available): if not can_proceed(bike.available):
raise ValidationError(detail=f'Transition from {bike.state} to {state}') raise ValidationError(detail=f'Transition from {bike.state} to {state} failed.')
bike.available() bike.available()
bike.save() bike.save()