Fixed error where voucher could not be deleted because of wrong route for delete function.

This commit is contained in:
Tanshu 2012-12-07 21:15:40 +05:30
parent 9b868ca71e
commit ee307e0e2c

View File

@ -82,7 +82,7 @@ def check_delete_permissions(request, voucher):
return response
@view_config(request_method='DELETE', route_name='api_voucher', renderer='json')
@view_config(request_method='DELETE', route_name='api_voucher_id', renderer='json')
def delete(request):
voucher = Voucher.by_id(uuid.UUID(request.matchdict['id']))
permission = check_delete_permissions(request, voucher)