We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 80469a6 commit 47978d7Copy full SHA for 47978d7
app/code/Magento/Checkout/view/frontend/web/js/view/progress-bar.js
@@ -23,11 +23,17 @@ define([
23
24
/** @inheritdoc */
25
initialize: function () {
26
+ var steps;
27
+
28
this._super();
29
window.addEventListener('hashchange', _.bind(stepNavigator.handleHash, stepNavigator));
30
31
if (!window.location.hash) {
- stepNavigator.setHash(stepNavigator.steps().sort(stepNavigator.sortItems)[0].code);
32
+ steps = stepNavigator.steps();
33
34
+ if (steps.length) {
35
+ stepNavigator.setHash(steps.sort(stepNavigator.sortItems)[0].code);
36
+ }
37
}
38
39
stepNavigator.handleHash();
0 commit comments