I found that when we update a node created through feedAPI, the feedAPI hook it, and in the line #959 it try to update the table feedapi:

db_query("UPDATE {feedapi} SET
url = '%s',
feed_type = '%s',
processors = '%s',
parsers = '%s',
link = '%s',
next_refresh_time = %d
WHERE vid = %d",
isset($node->feed->url) ? $node->feed->url : $node->feedapi['feedapi_url'],
isset($node->feed->feed_type) ? $node->feed->feed_type : '',
isset($node->feed->processors) ? serialize($node->feed->processors) : serialize($old_config->feed->processors),
isset($node->feed->parsers) ? serialize($node->feed->parsers) : serialize($old_config->feed->parsers),
isset($node->feed->options->link) ? $node->feed->options->link : '',
$next_refresh_time,
$node->vid
);

in the moment that it tries to get the actual link it faild:
isset($node->feed->options->link) ? $node->feed->options->link : ''

because the $node->feed->options doesnt even exists, so it cant find the link value and put "" in the query that actually erase the value.

For now, what I did in order to not alter the feedAPI, was that i use the hook_nodeapi in my module, and before to save the node, i did this:

$node->feed->options->link = $node->feed->link

in this way, this value can be obtained from $node->feed->options->link, and the feedAPI module can saved it correctly like it is expecting to find that value.

CommentFileSizeAuthor
#3 606564_erase_link.patch894 bytesAron Novak
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Vacilando’s picture

Same problem, subscribing.

Summit’s picture

Subscribing, greetings, Martijn

Aron Novak’s picture

Status: Active » Needs review
FileSize
894 bytes

Thanks for the really exact bug description!
Basically you supplied the patch, in an indirect way also :)
Can you confirm that the patch below helps?

DamienMcKenna’s picture

This worked for me and it also resolves #614108: Could not refresh feed error.

DamienMcKenna’s picture

Status: Needs review » Reviewed & tested by the community
Aron Novak’s picture

Status: Reviewed & tested by the community » Fixed

Committed! Thank you for the cooperation.

Status: Fixed » Closed (fixed)

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