What an awesome module. Thank you for sharing it!

I've tracked this down bug to lines 135 & 145 in tumblr_connect.module. Seems to be a problem with the Tumblr api, our side or theirs. Perhaps someone else know's the solution? In the meantime, I'm gonna look around myself...

Comments

mpaler’s picture

The reason updating was failing is because I had revisions enabled on my node type. When the node is updated in drupal, the node->vid is always set to the next node_revisions auto increment before it is passed to getByNode(). This causes a mismatch with the last vid saved to tumblr_connect_node.vid

Rather than mess with trying to figure out the correct vid of the node being edited, I suggest we simply pass in the $nid to the getByNode. I'm assuming there will always only be one unique row per node in the tumblr_connect_node table -- so I'm not sure we ever have to narrow the search by vid.

Simply removing vid from the query in getByNode fixes it for me:

  public function getByNode($nid, $vid) {
    $sql = 'SELECT id, post_id from {tumblr_connect_node} where nid = %d';
    $result = db_query($sql,  $nid);

But fixing this the right way gets its fingers into a few different places so I want to confirm this direction before I write up a full patch.

mattwmc’s picture

I'm getting the same error.

socialnicheguru’s picture

Version: 6.x-1.1 » 7.x-1.6

I am getting the error in Drupal 7.

I have enabled the module but not configured it yet.

socialnicheguru’s picture

Issue summary: View changes

give some thanks!