Solving the “Failed to execute ‘removeChild’ on ‘Node’” error on modern SharePoint pages