aboutsummaryrefslogtreecommitdiffstats
path: root/servo/views
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2016-11-03 09:25:22 +0200
committerFilipp Lepalaan <filipp@mac.com>2016-11-03 09:25:22 +0200
commit920bda8b69d2f2c078d369fe25684c437c50e40f (patch)
treece7886a78524d39c0a146045df91098cd914368c /servo/views
parent31ad3792ab44c7a1f3c66f54488b5e716c23990a (diff)
downloadServo-920bda8b69d2f2c078d369fe25684c437c50e40f.tar.gz
Servo-920bda8b69d2f2c078d369fe25684c437c50e40f.tar.bz2
Servo-920bda8b69d2f2c078d369fe25684c437c50e40f.zip
Use url name instead of view
Diffstat (limited to 'servo/views')
-rw-r--r--servo/views/order.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/servo/views/order.py b/servo/views/order.py
index 145e1f7..39ecb4c 100644
--- a/servo/views/order.py
+++ b/servo/views/order.py
@@ -788,7 +788,7 @@ def report_device(request, pk, device_id):
@permission_required('servo.change_order')
def remove_product(request, pk, item_id):
- order = Order.objects.get(pk=pk)
+ order = get_object_or_404(Order, pk=pk)
# The following is to help those who hit Back after removing a product
try: