Skip to content

Commit

Permalink
Issue #1707928 by joelpittet, jstoller, Polonium: PHP strict warning:…
Browse files Browse the repository at this point in the history
… Only variables should be passed by reference in .../modules/book/book.module on line 559
  • Loading branch information
jstoller authored and dsnopek committed Dec 17, 2018
1 parent 23454df commit befcc03
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules/book/book.module
Expand Up @@ -556,7 +556,8 @@ function book_prev($book_link) {
// The previous page in the book may be a child of the previous visible link.
if ($prev['depth'] == $book_link['depth'] && $prev['has_children']) {
// The subtree will have only one link at the top level - get its data.
$data = array_shift(book_menu_subtree_data($prev));
$subtree = book_menu_subtree_data($prev);
$data = array_shift($subtree);
// The link of interest is the last child - iterate to find the deepest one.
while ($data['below']) {
$data = end($data['below']);
Expand Down

0 comments on commit befcc03

Please sign in to comment.