@forge/lint 3.0.0-next.9 → 3.0.0

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,53 @@
1
1
  # @forge/lint
2
2
 
3
+ ## 3.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - 4922d09: Only errors set the process exitCode to 1, warnings do not anymore.
8
+
9
+ ### Minor Changes
10
+
11
+ - 83ca609: Adding environment variables to override production swagger with local files.
12
+ - 037c31a5: Upgrade webpack from 4 to 5 and other relavent packages to fix the issue for node17+ (openssl change)
13
+
14
+ ### Patch Changes
15
+
16
+ - ffa0050: Accept both deprecated scopes and granular scopes when verifying scopes required for Forge UI hooks.
17
+ - f5d4a63: Fix unhandled error when invalid method used for Product REST API endpoint.
18
+ - 1f7c428: Accept both deprecated scopes and granular scopes when verifying scopes required for REST product endpoints.
19
+ - 2e70a0b: Accept both granular and deprecated scopes when verifying scopes required for Content Properties.
20
+ - Updated dependencies [debe251]
21
+ - Updated dependencies [037c31a5]
22
+ - Updated dependencies [f6901fd]
23
+ - Updated dependencies [813f8f3]
24
+ - Updated dependencies [8ee1c58]
25
+ - Updated dependencies [67d2e17]
26
+ - Updated dependencies [14102be]
27
+ - Updated dependencies [7b2d17a]
28
+ - Updated dependencies [8aaa65c]
29
+ - Updated dependencies [d3ccc04]
30
+ - Updated dependencies [5152239]
31
+ - @forge/manifest@3.1.0
32
+ - @forge/cli-shared@2.2.1
33
+
34
+ ## 3.0.0-next.11
35
+
36
+ ### Patch Changes
37
+
38
+ - Updated dependencies [8aaa65c]
39
+ - @forge/manifest@3.1.0-next.9
40
+ - @forge/cli-shared@2.2.1-next.9
41
+
42
+ ## 3.0.0-next.10
43
+
44
+ ### Patch Changes
45
+
46
+ - f5d4a636: Fix unhandled error when invalid method used for Product REST API endpoint.
47
+ - Updated dependencies [67d2e17c]
48
+ - @forge/manifest@3.1.0-next.8
49
+ - @forge/cli-shared@2.2.1-next.8
50
+
3
51
  ## 3.0.0-next.9
4
52
 
5
53
  ### Minor Changes
@@ -73,23 +73,23 @@ class ProductVerifier extends verifier_interface_1.BaseLintIssueVerifier {
73
73
  return missingCurrentScopes;
74
74
  }
75
75
  getRequiredScopes({ regex, method }) {
76
- var _a, _b, _c;
76
+ var _a, _b, _c, _d;
77
77
  if (!regex)
78
78
  return [];
79
- const oAuth2Scopes = (_a = this.pathMap.get(regex)) === null || _a === void 0 ? void 0 : _a.methods[method]['x-atlassian-oauth2-scopes'];
79
+ const oAuth2Scopes = (_b = (_a = this.pathMap.get(regex)) === null || _a === void 0 ? void 0 : _a.methods[method]) === null || _b === void 0 ? void 0 : _b['x-atlassian-oauth2-scopes'];
80
80
  if (oAuth2Scopes) {
81
81
  return array_prototype_flatmap_1.default(oAuth2Scopes.filter((scope) => scope.state === 'Current').map((scope) => scope.scopes), (x) => x);
82
82
  }
83
- const swaggerEntries = (_c = (_b = this.pathMap.get(regex)) === null || _b === void 0 ? void 0 : _b.methods[method]) === null || _c === void 0 ? void 0 : _c.security;
83
+ const swaggerEntries = (_d = (_c = this.pathMap.get(regex)) === null || _c === void 0 ? void 0 : _c.methods[method]) === null || _d === void 0 ? void 0 : _d.security;
84
84
  if (!swaggerEntries)
85
85
  return [];
86
86
  return swaggerEntries === null || swaggerEntries === void 0 ? void 0 : swaggerEntries.reduce((prev, curr) => [...prev, ...(curr['OAuth2'] || []), ...(curr['oAuthDefinitions'] || [])], []);
87
87
  }
88
88
  getRequiredDeprecatedScopes({ regex, method }) {
89
- var _a;
89
+ var _a, _b;
90
90
  if (!regex)
91
91
  return [];
92
- const oAuth2Scopes = (_a = this.pathMap.get(regex)) === null || _a === void 0 ? void 0 : _a.methods[method]['x-atlassian-oauth2-scopes'];
92
+ const oAuth2Scopes = (_b = (_a = this.pathMap.get(regex)) === null || _a === void 0 ? void 0 : _a.methods[method]) === null || _b === void 0 ? void 0 : _b['x-atlassian-oauth2-scopes'];
93
93
  if (!oAuth2Scopes)
94
94
  return [];
95
95
  return array_prototype_flatmap_1.default(oAuth2Scopes.filter((scope) => scope.state === 'Deprecated').map((scope) => scope.scopes), (x) => x);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forge/lint",
3
- "version": "3.0.0-next.9",
3
+ "version": "3.0.0",
4
4
  "description": "Linting for forge apps",
5
5
  "main": "out/index.js",
6
6
  "license": "UNLICENSED",
@@ -15,9 +15,9 @@
15
15
  "@types/node-fetch": "^2.5.7"
16
16
  },
17
17
  "dependencies": {
18
- "@forge/cli-shared": "2.2.1-next.7",
18
+ "@forge/cli-shared": "2.2.1",
19
19
  "@forge/csp": "1.9.0",
20
- "@forge/manifest": "3.1.0-next.7",
20
+ "@forge/manifest": "3.1.0",
21
21
  "@typescript-eslint/typescript-estree": "^3.5.0",
22
22
  "cross-spawn": "^7.0.1",
23
23
  "node-fetch": "2.6.1",