# Fixes bug

* fixes bug described in #331
This commit is contained in:
2023-05-16 12:11:13 +02:00
parent dc052a96cb
commit 0664604804

View File

@@ -79,8 +79,6 @@ class AbstractEditDeductionView(AbstractDeductionView):
self._custom_check(obj)
try:
eco_deduction = obj.deductions.get(id=deduction_id)
if not eco_deduction.intervention.is_shared_with(request.user):
raise ObjectDoesNotExist
except ObjectDoesNotExist:
raise Http404(DEDUCTION_UNKNOWN)
@@ -119,8 +117,6 @@ class AbstractRemoveDeductionView(AbstractDeductionView):
self._custom_check(obj)
try:
eco_deduction = obj.deductions.get(id=deduction_id)
if not eco_deduction.intervention.is_shared_with(request.user):
raise ObjectDoesNotExist()
except ObjectDoesNotExist:
raise Http404(DEDUCTION_UNKNOWN)
form = RemoveEcoAccountDeductionModalForm(request.POST or None, instance=obj, deduction=eco_deduction,