repository-provider 30.3.1 → 30.3.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "repository-provider",
3
- "version": "30.3.1",
3
+ "version": "30.3.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -36,7 +36,7 @@
36
36
  "ava": "^4.2.0",
37
37
  "c8": "^7.11.3",
38
38
  "documentation": "^13.2.5",
39
- "repository-provider-test-support": "^2.1.22",
39
+ "repository-provider-test-support": "^2.1.23",
40
40
  "semantic-release": "^19.0.2",
41
41
  "typescript": "^4.7.2"
42
42
  },
package/src/attribute.mjs CHANGED
@@ -193,17 +193,19 @@ export function optionJSON(
193
193
  initial = {},
194
194
  attributes = object.constructor.attributes
195
195
  ) {
196
- return attributes ? Object.keys(attributes).reduce((a, c) => {
197
- const value = object[c];
198
- if (value !== undefined && !(value instanceof Function)) {
199
- if (value instanceof Set) {
200
- a[c] = [...value];
201
- } else {
202
- a[c] = value;
203
- }
204
- }
205
- return a;
206
- }, initial) : initial;
196
+ return attributes
197
+ ? Object.keys(attributes).reduce((a, c) => {
198
+ const value = object[c];
199
+ if (value !== undefined && !(value instanceof Function)) {
200
+ if (value instanceof Set) {
201
+ a[c] = [...value];
202
+ } else {
203
+ a[c] = value;
204
+ }
205
+ }
206
+ return a;
207
+ }, initial)
208
+ : initial;
207
209
  }
208
210
 
209
211
  /**
@@ -31,6 +31,10 @@ export class PullRequest extends OwnedObject {
31
31
  return "_addPullRequest";
32
32
  }
33
33
 
34
+ static get type() {
35
+ return "pull-request";
36
+ }
37
+
34
38
  static get collectionName() {
35
39
  return "pullRequests";
36
40
  }