Commit 95907f0c authored by Steven Wittens's avatar Steven Wittens
Browse files

- Fixing broken drupal_goto() after node submission on PHP5.

parent 7fe195a0
......@@ -1677,9 +1677,9 @@ function node_page() {
print theme('page', node_preview($edit));
break;
case t('Submit'):
if (node_submit($edit)) {
if ($nid = node_submit($edit)) {
if (node_access('view', $edit)) {
drupal_goto('node/'. $edit->nid);
drupal_goto('node/'. $nid);
}
else {
drupal_goto();
......
......@@ -1677,9 +1677,9 @@ function node_page() {
print theme('page', node_preview($edit));
break;
case t('Submit'):
if (node_submit($edit)) {
if ($nid = node_submit($edit)) {
if (node_access('view', $edit)) {
drupal_goto('node/'. $edit->nid);
drupal_goto('node/'. $nid);
}
else {
drupal_goto();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment