Problem/Motivation

The preprocess node seems to check a node type "on_demand_tutorial" which seem wrong and is not defined in the config. I guess it is supposed to be youtube_playlists

/**
 * Implements hook_preprocess_node().
 */
function youtube_playlists_preprocess_node(&$variables) {
  if ($variables['node']->getType() == 'on_demand_tutorial') {
    $youtube_link = $variables['node']->get('field_youtube_url')->uri;
    if (!empty($youtube_link)) {
      // Override the node URL with the youtube_link.
      $variables['url'] = $youtube_link;
    }
  }
}

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Comments

phjou created an issue. See original summary.

sourabhsisodia_’s picture

Assigned: Unassigned » sourabhsisodia_

sudarshan giri’s picture

Status: Active » Fixed
sourabhsisodia_’s picture

Assigned: sourabhsisodia_ » Unassigned

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.