Corrupted book data can be impossible to delete
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3556284. -->
Reported by: [liam morland](https://www.drupal.org/user/493050)
Related to !137
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>We had a bunch of nodes that have book data associated, but this data is corrupted (I don't know how we got into this situation). To fix it, I created a VBO to fun <code>BookManager::deleteFromBook()</code> on the nodes. This was failing in <code>::updateOriginalParent()</code>; it would throw <code>InvalidArgumentException</code>, 'Missing key "pid" in original book item'.</p>
<h3 id="summary-proposed-resolution">Proposed resolution</h3>
<p>If <code>pid</code> is not set, do not throw an exception. Instead, just don't try to remove the parents. I made this change and it fixed the situation for us.</p>
<h3 id="summary-remaining-tasks">Remaining tasks</h3>
<p>Implement.</p>
<h3 id="summary-ui-changes">User interface changes</h3>
<p>None.</p>
<h3 id="summary-api-changes">API changes</h3>
<p>None.</p>
<h3 id="summary-data-model-changes">Data model changes</h3>
<p>None.</p>
issue