If I import nodes using feeds, and the node type has domain source set to Use Active Domain for example, no record is inserted into domain_source table. If I edit the node after import, the Source domain is showing Use Active Domain as expected, but this probably comes from field's default value, since no record is in domain_source table. Since there's no record in domain_source, domain_source_domain_source_alter couldn't find the domain source for this node, and would not assign the correct domain for this node when a link to the node is displayed.

Comments

agentrickard’s picture

Category: Bug report » Support request
Issue summary: View changes
Status: Active » Postponed (maintainer needs more info)

How is this not a Feeds mapping issue?

jrao’s picture

Sorry, it's been a long time, so I don't remember what happened back then. But just by reading the original description, my guess would be this: The domain source should still work even if we didn't add it in the mapping, i.e. it should have appropriate default built-in when a node is added. This is true when we add the node via GUI, but not so when importing node via feeds.

agentrickard’s picture

Status: Postponed (maintainer needs more info) » Active

The module is expecting a value to be set, else it doesn't fire.

/**
 * Implements hook_node_insert()
 */
function domain_source_node_insert($node) {
  // If not set, we ignore.
  if (!isset($node->domain_source) || is_null($node->domain_source)) {
    return;
  }

That may not be a proper assumption, because it means that Domain Source is form dependent.

agentrickard’s picture

Status: Active » Closed (won't fix)