Skip to content

Commit

Permalink
Updated ResourceModel in order to accept Single-Store mode magento setup
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Burzyński committed Jun 2, 2021
1 parent 09e6e5e commit 39ba79b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Model/ResourceModel/Menu.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ protected function _setStoreIds(\Magento\Framework\Model\AbstractModel $object)
$menuData = $request->getParam('menu');

if ($menuData && isset($menuData['store_id'])) {
if (in_array(0, $menuData['store_id'])) {
if (is_string($menuData['store_id']) or in_array(0, $menuData['store_id'])) {
$object->setData('stores', [0]);
} else {
$object->setData('stores', $menuData['store_id']);
Expand Down

0 comments on commit 39ba79b

Please sign in to comment.