fixed the js file so the item to delete would be removed from the page when deleted