We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a0087b3 commit 5ba647eCopy full SHA for 5ba647e
src/allocation/exceptions.py
@@ -1,6 +1,3 @@
1
-class OutOfStock(Exception):
2
- pass
3
-
4
class InvalidSku(Exception):
5
pass
6
src/allocation/flask_app.py
@@ -27,7 +27,7 @@ def allocate_endpoint():
27
request.json['qty'],
28
unit_of_work.SqlAlchemyUnitOfWork(),
29
)
30
- except (exceptions.OutOfStock, exceptions.InvalidSku) as e:
+ except exceptions.InvalidSku as e:
31
return jsonify({'message': str(e)}), 400
32
33
return jsonify({'batchref': batchref}), 201
0 commit comments