I had posted a problem here http://drupal.org/node/172971#comment-268224, which I will copy & paste here:

Hi

I get a strange confirmation message when I submit or edit some content:

Your Audio has been created.

after I submitted some self-made content, a proverb! or

The Audio has been updated.

on updating a recipe!!

None of them has anything to do with "audio". What could be wrong & how do I correct it? No idea what could be triggering that.

THat also happened when submitting a forum topic.

After reporting to the recipe module folks, one had suggested some other module may be interfering with the input.

After remembering I recently installed the new version of the audio module & that this problem was just a few days old, I uninstalled it & downloaded & reinstalled the older version.

The error did not turn up again.

So there may be something small in it causing that ....

CommentFileSizeAuthor
#8 audio.module.tokenfix.patch478 bytesrjleigh

Comments

drewish’s picture

i've seen that too... hadn't had a chance to track it down though. any hints would be appreciated.

alpinejag’s picture

I've been noticing this as well.

drewish’s picture

Title: A bug in the new audio version? » Creating any node type reports:"Your Audio has been created."

marked http://drupal.org/node/178415 as a duplicate... probably because this had a really bad title.

lionheart8’s picture

Ok, thanks for the correction.

In Audio 5.x-1.3, I think released 25th September, a preliminary test seems to show the problem has been solved. I will post if I notice anything bad.

drewish’s picture

i think the issue is specific to 2.x-dev releases.

kyle_mathews’s picture

I'm seeing the same problem running 5.2-2.x-dev

kyle_mathews’s picture

I spent awhile this evening trying to track down the source of this bug. I haven't fixed it but I've identified where it starts.

In node.module line 2321 is the code for that sets the "Your {node-type} has been created" message. This message is set just after the node is saved to the database. When the node is saved to the database, the "type" is correct as you can check by looking at the node table. But somewhere (I'm guessing) in the node_save function, $node->type is changed from the original content type to audio. This can be seen both in the message sent to the screen and in the log message. Any experienced drupalers that can help me out from here?

Relevant code from node.module

 node_save($node);
    watchdog('content', t('@type: added %title.', array('@type' => t($node->type), '%title' => $node->title)), WATCHDOG_NOTICE, l(t('view'), "node/$node->nid"));
    drupal_set_message(t('Your %post has been created.', array('%post' => node_get_types('name', $node))));
  }
rjleigh’s picture

Assigned: Unassigned » rjleigh
Priority: Normal » Critical
Status: Active » Reviewed & tested by the community
StatusFileSize
new478 bytes

Wow, this was a tough one (at least for me) - took hours of tracing to locate. And it's not a minor message issue either (as I first thought)- it will affect all pathauto assignments on a site! (perhaps other token-related issues as well - that's why I marked it critical)

But the fix is incredibly simple - it's just a bad comparison operator.

--Roger

rjleigh’s picture

just for cross reference I found this: http://drupal.org/node/193472

--Roger

drewish’s picture

Status: Reviewed & tested by the community » Fixed

great/doh! dumb mistake on my part. thanks for tracking that down. i've committed the patch to HEAD.

Anonymous’s picture

Status: Fixed » Closed (fixed)

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