When creating a new node that is part of a book the module gives the following warnings in the logs.

Warning: Trying to access array offset on value of type bool in Drupal\book\BookManager->bookSubtreeData() (line 1147 of /var/www/html/docroot/core/modules/book/src/BookManager.php)

Warning: Trying to access array offset on value of type bool in Drupal\book_link_weight\Form\BookLinkWeightForm->alterBookOutlineForm() (line 71 of /var/www/html/docroot/modules/contrib/book_link_weight/src/Form/BookLinkWeightForm.php)

This is caused by $form['book']['pid']['#default_value'] been = '-1' so no tree data is been loaded.

I will submit a merge request with a possible fix.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

lstirk created an issue. See original summary.

  • andy_w committed 3cfef7f0 on 1.0.x authored by lstirk
    Issue #3425984 by lstirk: Warnings in logs from the node add form
    
andy_w’s picture

Status: Active » Fixed
andy_w’s picture

Status: Fixed » Closed (fixed)