@scandipwa/magento-scripts 1.14.1-alpha.1 → 1.14.1-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -61,18 +61,20 @@ const setupESLintConfig = () => ({
61
61
  }
62
62
  };
63
63
  const themes = await getCSAThemes();
64
- const theme = themes[0];
65
64
 
66
- if (await pathExists(theme.themePath)) {
67
- styleLintConfigurationData.project.component['work-dir-pattern'] = {
68
- [valueKey]: formatPathForPHPStormConfig(theme.themePath)
69
- };
70
- const packageJsonPath = path.join(theme.themePath, 'package.json');
71
- if (await pathExists(packageJsonPath)) {
72
- styleLintConfigurationData.project.component['custom-configuration-file'] = {
73
- '@_used': 'true',
74
- '@_path': formatPathForPHPStormConfig(packageJsonPath)
65
+ if (themes.length > 0) {
66
+ const theme = themes[0];
67
+ if (await pathExists(theme.themePath)) {
68
+ styleLintConfigurationData.project.component['work-dir-pattern'] = {
69
+ [valueKey]: formatPathForPHPStormConfig(theme.themePath)
75
70
  };
71
+ const packageJsonPath = path.join(theme.themePath, 'package.json');
72
+ if (await pathExists(packageJsonPath)) {
73
+ styleLintConfigurationData.project.component['custom-configuration-file'] = {
74
+ '@_used': 'true',
75
+ '@_path': formatPathForPHPStormConfig(packageJsonPath)
76
+ };
77
+ }
76
78
  }
77
79
  }
78
80
 
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Scripts and configuration used by CMA.",
4
4
  "homepage": "https://docs.create-magento-app.com/",
5
5
  "repository": "github:scandipwa/create-magento-app",
6
- "version": "1.14.1-alpha.1",
6
+ "version": "1.14.1-alpha.2",
7
7
  "main": "./index.js",
8
8
  "types": "./typings/index.d.ts",
9
9
  "license": "OSL-3.0",
@@ -52,5 +52,5 @@
52
52
  "mysql",
53
53
  "scandipwa"
54
54
  ],
55
- "gitHead": "cc46e60ca1d44d6e00b151e03af5cc7f56a5e54a"
55
+ "gitHead": "8f43ab3d68af6442bbd618efd785654ac62e54b8"
56
56
  }