Skip to content

Commit 33c7f7e

Browse files
authored
[CommerceExtension] Fix crash when choosing default store (#42) (#513)
1 parent 878aa5c commit 33c7f7e

File tree

1 file changed

+2
-1
lines changed
  • app/code/Meta/BusinessExtension/Block/Adminhtml

1 file changed

+2
-1
lines changed

app/code/Meta/BusinessExtension/Block/Adminhtml/Setup.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,8 +132,9 @@ public function getSelectedStoreId()
132132
}
133133
}
134134

135+
135136
// No default found, return the first store.
136-
$firstStore = array_slice($stores, 0, 1)[0];
137+
$firstStore = array_shift($stores);
137138
return $firstStore['store_id'];
138139
}
139140

0 commit comments

Comments
 (0)