Throw NotFoundHttpException if accessing a non-existant book
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3556288. -->
Reported by: [liam morland](https://www.drupal.org/user/493050)
Related to !141 !138
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>If a user accesses a book that does not exist (<code>admin/structure/book/NNN</code>), the result will be <code>TypeError: Drupal\book\ProxyClass\BookManager::bookSubtreeData(): Argument #1 ($link) must be of type array, null given</code>. It ought to return HTTP 404.</p>
<h3 id="summary-proposed-resolution">Proposed resolution</h3>
<p>Throw <code>NotFoundHttpException</code>.</p>
<h3 id="summary-remaining-tasks">Remaining tasks</h3>
<p>Implement.</p>
<h3 id="summary-ui-changes">User interface changes</h3>
<p>None, except for a better experience with non-existent books.</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