From c41d0aa92439f57489a6fd1b0dce65919ddff680 Mon Sep 17 00:00:00 2001 From: Mike Gerwitz Date: Mon, 23 Oct 2017 14:56:51 -0400 Subject: [PATCH] GeneralStepUi: Do not try to sort one group An error was being thrown because there are no siblings to reference when there is only a single group. Obviously sorting is not even needed in such a situation. src/ui/step/GeneralStepUi.js (_sortGroups): Abort if <= 1 groups. --- src/ui/step/GeneralStepUi.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/ui/step/GeneralStepUi.js b/src/ui/step/GeneralStepUi.js index de3fbb9..ddc89e2 100644 --- a/src/ui/step/GeneralStepUi.js +++ b/src/ui/step/GeneralStepUi.js @@ -1102,7 +1102,8 @@ module.exports = Class( 'GeneralStepUi' ) var len = ids.length, groups = []; - if ( len === 0 ) + // if one group (or none), nothing to sort + if ( len <= 1 ) { return; }