diff --git a/workflow.module b/workflow.module
index 6a9aff2..d99ba7b 100644
--- a/workflow.module
+++ b/workflow.module
@@ -234,11 +234,20 @@ function workflow_transition($node, $sid) {
  *   An array of possible target states.
  */
 function workflow_node_form(&$form, $form_state, $title, $name, $current, $choices, $timestamp = NULL, $comment = NULL) {
+  // If the current node state is not one of the choices, autoselect first choice.
+  // We know all states in $choices are states that user has permission to
+  // go to because workflow_field_choices() has already checked that.
+  if (!isset($choices[$current])) {
+    $array = array_keys($choices);
+    $current = $array[0];
+  }
+
   // No sense displaying choices if there is only one choice.
   if (sizeof($choices) == 1) {
     $form['workflow'][$name] = array(
       '#type' => 'hidden',
-      '#value' => $current
+      '#value' => $current,
+      '#parents' => array('workflow'),
     );
   }
   else {
@@ -340,14 +349,6 @@ function workflow_form_alter(&$form, $form_state, $form_id) {
     $form['#wf'] = $workflow;
     $name = check_plain($workflow->name);
 
-    // If the current node state is not one of the choices, autoselect first choice.
-    // We know all states in $choices are states that user has permission to
-    // go to because workflow_field_choices() has already checked that.
-    if (!isset($choices[$current])) {
-      $array = array_keys($choices);
-      $current = $array[0];
-    }
-
     if (sizeof($choices) > 1) {
       $form['workflow'] = array(
         '#type' => 'fieldset',
