Skip to content

Commit

Permalink
edit_ethics: return 404 for missing query parameter.
Browse files Browse the repository at this point in the history
  • Loading branch information
Benjamin Moody committed May 6, 2024
1 parent 5001b8f commit fb9f581
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions physionet-django/project/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -1518,6 +1518,8 @@ def edit_ethics(request, project_slug, **kwargs):
elif request.method == 'POST' and 'remove_id' in request.POST:
extra_forms = 0
UploadedDocument.objects.get(id=int(request.POST['remove_id'])).delete()
else:
raise Http404()

UploadedSupportingDocumentFormSet = generic_inlineformset_factory(
UploadedDocument,
Expand Down

0 comments on commit fb9f581

Please sign in to comment.