Skip to content

Instantly share code, notes, and snippets.

View lukerhd's full-sized avatar

Luke Adams lukerhd

View GitHub Profile
( ! ) Fatal error: Method HighWire\Parser\Markup\Markup::__toString() must not throw an exception, caught Drupal\highwire_content\Exception\ApathNotFoundException: The apaths /mheaeworks/book/9780071428675/chapter/chapter9/search-section/section817.atom could not be found in /opt/sites/scolaris-mhe_stage_pre_content_load/site-repo/releases/20180923162624/web/core/lib/Drupal/Component/Render/MarkupTrait.php on line 0
Call Stack
# Time Memory Function Location
1 0.0001 367568 {main}( ) .../index.php:0
2 0.0041 488416 Drupal\Core\DrupalKernel->handle( ) .../index.php:19
3 0.0185 1892112 Stack\StackedHttpKernel->handle( ) .../DrupalKernel.php:663
4 0.0185 1892112 Drupal\Core\StackMiddleware\NegotiationMiddleware->handle( ) .../StackedHttpKernel.php:23
5 0.0186 1892112 Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle( ) .../NegotiationMiddleware.php:50
6 0.0186 1892112 Drupal\Core\StackMiddleware\KernelPreHandle->handle( ) .../ReverseProxyMiddleware.php:47
function scolaris_mhe_search_form_views_exposed_form_alter(&$form, FormStateInterface $form_state, $form_id) {
if ($form['#id'] == 'views-exposed-form-search-page-1') {
$current_route = \Drupal::routeMatch()->getRouteName();
$options = FALSE;
// Check if we're on a node page.
if ($current_route == 'entity.node.canonical') {
$node = \Drupal::routeMatch()->getParameter('node');
// We only want additional options for the book, chapter
// and section node types.