@sap-ux/project-access 1.16.2 → 1.16.3

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.
@@ -176,20 +176,22 @@ function findRootsForPath(path) {
176
176
  // in root -> not supported
177
177
  return null;
178
178
  }
179
- // Now we have the app root folder. Check for freestyle non CAP
180
- if ((yield (0, file_1.fileExists)((0, path_1.join)(appRoot, constants_1.FileName.Ui5LocalYaml))) &&
181
- (0, dependencies_1.hasDependency)(appPckJson, '@sap/ux-ui5-tooling')) {
179
+ // Check if app is included in CAP project
180
+ const projectRoot = yield findCapProjectRoot(appRoot);
181
+ if (projectRoot) {
182
+ // App included in CAP
182
183
  return {
183
184
  appRoot,
184
- projectRoot: appRoot
185
+ projectRoot
185
186
  };
186
187
  }
187
- // Project must be CAP, find project root
188
- const projectRoot = yield findCapProjectRoot(appRoot);
189
- if (projectRoot) {
188
+ else if (
189
+ // Check for freestyle non CAP
190
+ (yield (0, file_1.fileExists)((0, path_1.join)(appRoot, constants_1.FileName.Ui5LocalYaml))) &&
191
+ (0, dependencies_1.hasDependency)(appPckJson, '@sap/ux-ui5-tooling')) {
190
192
  return {
191
193
  appRoot,
192
- projectRoot
194
+ projectRoot: appRoot
193
195
  };
194
196
  }
195
197
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sap-ux/project-access",
3
- "version": "1.16.2",
3
+ "version": "1.16.3",
4
4
  "description": "Library to access SAP Fiori tools projects",
5
5
  "repository": {
6
6
  "type": "git",