Here is the block of code that was causing issues:

// Prepare extra variables (hardcoded for node for now)
// TODO think of a cleaner sollution.
if ($this->nid > 0 && $node = node_load($this->nid)) {
  $this->variables['node_type'] = $node->type;
  $this->variables['node_status'] = $node->status;
  $this->variables['node_uid'] = $node->uid;
}
if ($this->nid_target > 0 && $node = node_load($this->nid_target)) {
  $this->variables['node_target_type'] = $node->type;
  $this->variables['node_target_status'] = $node->status;
  $this->variables['node_target_uid'] = $node->uid;
}

This block of code is related to Organic Groups because when the nid or nid_target is 0, it stored these vars. Although I cannot recall the specific instance where this gave me issues, I seem to remember it incorrectly stored values in the HB records that didn't belong there, and possibly throwing errors. I ended up commenting these lines out after coding a work-around for OG context with heartbeat (see issue 1555006).

thanks for looking into this

Comments

Stalski’s picture

Status: Active » Closed (cannot reproduce)

This works fine as it should. This code is only used to check access with the node_access function. I can't imagine it would break anything.