Scenario:
Two language site -- en, it
Create a node in English. Uncheck the "Generate automatic URL alias" checkbox and manually insert an alias.
Create a translation of the node in Italian. Uncheck it's auto URL alias check, create and alias and save.
The Italian node has the manually created alias, but the English node now has an automatically generated alias and its "Generate automatic URL alias" checkbox is checked.
In examining the process, it looks like pathauto_node_update_alias() gets called for each translated node, because of my translation synchronization settings.
However, in the translated nodes processed AFTER the actual node being edited, the $node->path property is not set.
On line 460 in pathauto.module, changing the test to the following causes the correct behavior, though I'm not sure this is the correct solution:
Old code:
if (isset($node->path['pathauto']) && empty($node->path['pathauto'])) {
My "fix":
if (!isset($node->path) || (isset($node->path['pathauto']) && empty($node->path['pathauto']))) {
Comments
Comment #1
giorgoskif entity translatable nodes are used
are you using the patch in #1155134: Integrate pathauto bulk generation ?
Comment #2
aacraig commentedI'm using the standard i18n module. I am not using entity translatable.
Comment #3
dave reidThis is a duplicate of #936222: Merge in pathauto_persist module functionality to prevent losing manual aliases with node_save() calls.