From ae0f1553f3b3711d5229573ff70e308243d94fe8 Mon Sep 17 00:00:00 2001 From: Matt Huntington Date: Fri, 10 Nov 2023 14:28:06 -0500 Subject: [PATCH] oops --- app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.js b/app.js index 7de38a4..3e4ccd5 100644 --- a/app.js +++ b/app.js @@ -40,7 +40,7 @@ const createNewItem = (event)=>{ attachDragEvents(newItem) if(event){ - event.currentTarget.parentNode.querySelector('ul').appendChild(newItem) + event.currentTarget.closest('li').querySelector('ul').appendChild(newItem) } else { document.querySelector('ul').appendChild(newItem) }