Index: pathauto.inc =================================================================== --- pathauto.inc (revision 219) +++ pathauto.inc (working copy) @@ -316,6 +316,10 @@ array('%original_alias' => $original_alias, '%alias' => $alias))); } } + + if ($op == 'return') { + return $alias; + } // If $pid is NULL, a new alias is created - otherwise, the existing // alias for the designated src is replaced Index: pathauto.module =================================================================== --- pathauto.module (revision 219) +++ pathauto.module (working copy) @@ -289,10 +289,13 @@ drupal_add_js(drupal_get_path('module', 'pathauto') .'/pathauto.js'); $form['path']['#collapsed'] = FALSE; + $placeholders = pathauto_get_placeholders('node', $node); + $alias = pathauto_create_alias('node', 'return', $placeholders, "node/{$node->nid}", $node->nid, $node->type, $node->language); + $form['path']['pathauto_perform_alias'] = array( '#type' => 'checkbox', '#title' => t('Automatic alias'), - '#default_value' => isset($node->pathauto_perform_alias) ? $node->pathauto_perform_alias : TRUE, + '#default_value' => !$node->pathauto_perform_alias && (!isset($node->path) || ($alias == $node->path)), '#description' => $output, '#weight' => -1, );