It's better to replace the line

  if (isset($types[$bundle]) && $data[$type]) {

by

  if (isset($types[$bundle]) && !empty($data[$type])) {

in node_token_tokens() function since $data may contain just 'node' key in some cases, and Undefined index warning is shown.

Comments

maximpodorov created an issue. See original summary.

  • validoll committed 4bf9332 on 8.x-1.x
    Issue #3070178: Undefine index warning in node_token_tokens()
    
validoll’s picture

Status: Active » Fixed

Fixed. Thank you!

validoll’s picture

Status: Fixed » Closed (fixed)