Commit 00c87254 authored by Gábor Hojtsy's avatar Gábor Hojtsy

#89376 by Eaton: add the preview build mode flag prior to hook_form() being called

parent 1800ea94
...@@ -104,6 +104,9 @@ function node_form(&$form_state, $node) { ...@@ -104,6 +104,9 @@ function node_form(&$form_state, $node) {
if (!isset($form_state['node_preview'])) { if (!isset($form_state['node_preview'])) {
node_object_prepare($node); node_object_prepare($node);
} }
else {
$node->build_mode = NODE_BUILD_PREVIEW;
}
// Set the id of the top-level form tag // Set the id of the top-level form tag
$form['#id'] = 'node-form'; $form['#id'] = 'node-form';
......
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