@@ -51,8 +51,7 @@ discard block |
||
| 51 | 51 | for ($i = 0; $i < $_argument['category-number']; $i++) { |
| 52 | 52 | if(!is_null($_argument['category-name-prefix'])) { |
| 53 | 53 | $name = $_argument['category-name-prefix'] . " " . $i; |
| 54 | - } |
|
| 55 | - else { |
|
| 54 | + } else { |
|
| 56 | 55 | $name = self::DEFAULT_CATEGORY_NAME . " " . $i; |
| 57 | 56 | } |
| 58 | 57 | |
@@ -76,10 +75,11 @@ discard block |
||
| 76 | 75 | $category->setDisplayMode('PRODUCTS'); |
| 77 | 76 | $category->setIsAnchor(self::DEFAULT_CATEGORY_ANCHOR); |
| 78 | 77 | |
| 79 | - if(\Mage::getVersion() === "1.5.1.0") |
|
| 80 | - $category->setStoreId(array(0,$_argument['store-id'])); |
|
| 81 | - else |
|
| 82 | - $category->setStoreId($_argument['store-id']); |
|
| 78 | + if(\Mage::getVersion() === "1.5.1.0") { |
|
| 79 | + $category->setStoreId(array(0,$_argument['store-id'])); |
|
| 80 | + } else { |
|
| 81 | + $category->setStoreId($_argument['store-id']); |
|
| 82 | + } |
|
| 83 | 83 | $parentCategory = \Mage::getModel('catalog/category')->load($_category_root_id); |
| 84 | 84 | $category->setPath($parentCategory->getPath()); |
| 85 | 85 | |
@@ -98,10 +98,11 @@ discard block |
||
| 98 | 98 | $category->setDisplayMode('PRODUCTS'); |
| 99 | 99 | $category->setIsAnchor(self::DEFAULT_CATEGORY_ANCHOR); |
| 100 | 100 | |
| 101 | - if(\Mage::getVersion() === "1.5.1.0") |
|
| 102 | - $category->setStoreId(array(0,$_argument['store-id'])); |
|
| 103 | - else |
|
| 104 | - $category->setStoreId($_argument['store-id']); |
|
| 101 | + if(\Mage::getVersion() === "1.5.1.0") { |
|
| 102 | + $category->setStoreId(array(0,$_argument['store-id'])); |
|
| 103 | + } else { |
|
| 104 | + $category->setStoreId($_argument['store-id']); |
|
| 105 | + } |
|
| 105 | 106 | $parentCategory = \Mage::getModel('catalog/category')->load($_parent_id); |
| 106 | 107 | $category->setPath($parentCategory->getPath()); |
| 107 | 108 | |