From ef7ce4d2e460c3b83ac0fe56e0d487183e0c4a53 Mon Sep 17 00:00:00 2001
From: Scott Rigby <srigby+dlc-solutions.com>
Date: Tue, 31 Jan 2012 12:30:29 -0500
Subject: [PATCH] Issue #1423128: initialize navigation data array, sort, then
 pass only values to theme function

---
 multistep.module |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/multistep.module b/multistep.module
index aa17c84..4c522af 100644
--- a/multistep.module
+++ b/multistep.module
@@ -165,6 +165,7 @@ function _multistep_block($type) {
       $workflow_mode = variable_get('multistep_workflow_mode', 'free');
       $current_step = _multistep_get_current_step($type);
       // Generate the menu items.
+      $data = array();
       if (variable_get('multistep_menu_' . $type, 'enabled') == 'enabled') {
         foreach ($groups as $group) {
           if ($group['settings']['multistep']['block']) {
@@ -193,7 +194,8 @@ function _multistep_block($type) {
             }
           }
         }
-      $menu = theme('multistep_navigation', $data);
+        ksort($data);
+        $menu = theme('multistep_navigation', array_values($data));
       }
       // Generate the progress bar.
       if (variable_get('multistep_progress_' . $type, 'enabled') == 'enabled') {
--
1.7.5.4

