From b9b56941654de5101f78121934a9a17a35122b41 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Sun, 31 Jan 2021 13:14:52 -0800 Subject: [PATCH] Fixes bug in removing list item --- bookwyrm/views/list.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bookwyrm/views/list.py b/bookwyrm/views/list.py index 2e9afe33..4b7a4de4 100644 --- a/bookwyrm/views/list.py +++ b/bookwyrm/views/list.py @@ -169,7 +169,7 @@ def remove_book(request, list_id): book_list = get_object_or_404(models.List, id=list_id) item = get_object_or_404(models.ListItem, id=request.POST.get('item')) - if not book_list.user == request.user and not item.user == request.user: + if not book_list.user == request.user and not item.added_by == request.user: return HttpResponseNotFound() item.delete()