repository-provider 32.4.8 → 32.4.9
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/README.md +18 -18
- package/package.json +2 -2
- package/src/base-object.mjs +2 -2
- package/src/owned-object.mjs +5 -0
- package/src/ref.mjs +2 -2
- package/src/repository-owner.mjs +4 -7
package/README.md
CHANGED
|
@@ -64,11 +64,11 @@ console.log(await readme.getString());
|
|
|
64
64
|
* [Parameters](#parameters-6)
|
|
65
65
|
* [mapAttributesInverse](#mapattributesinverse)
|
|
66
66
|
* [Parameters](#parameters-7)
|
|
67
|
-
* [description](#
|
|
68
|
-
* [id](#
|
|
69
|
-
* [body](#
|
|
70
|
-
* [title](#
|
|
71
|
-
* [priority](#
|
|
67
|
+
* [description\_attribute](#description_attribute)
|
|
68
|
+
* [id\_attribute](#id_attribute)
|
|
69
|
+
* [body\_attribute](#body_attribute)
|
|
70
|
+
* [title\_attribute](#title_attribute)
|
|
71
|
+
* [priority\_attribute](#priority_attribute)
|
|
72
72
|
* [BaseObject](#baseobject)
|
|
73
73
|
* [Parameters](#parameters-8)
|
|
74
74
|
* [update](#update)
|
|
@@ -185,7 +185,6 @@ console.log(await readme.getString());
|
|
|
185
185
|
* [Parameters](#parameters-41)
|
|
186
186
|
* [toJSON](#tojson-1)
|
|
187
187
|
* [attributes](#attributes-1)
|
|
188
|
-
* [homePageURL](#homepageurl)
|
|
189
188
|
* [OwnedObject](#ownedobject)
|
|
190
189
|
* [Parameters](#parameters-42)
|
|
191
190
|
* [delete](#delete-1)
|
|
@@ -252,7 +251,7 @@ console.log(await readme.getString());
|
|
|
252
251
|
* [fullCondensedName](#fullcondensedname-1)
|
|
253
252
|
* [toString](#tostring-1)
|
|
254
253
|
* [issuesURL](#issuesurl)
|
|
255
|
-
* [homePageURL](#homepageurl
|
|
254
|
+
* [homePageURL](#homepageurl)
|
|
256
255
|
* [isLocked](#islocked)
|
|
257
256
|
* [isArchived](#isarchived)
|
|
258
257
|
* [isDisabled](#isdisabled)
|
|
@@ -264,6 +263,7 @@ console.log(await readme.getString());
|
|
|
264
263
|
* [Properties](#properties-9)
|
|
265
264
|
* [attributeMapping](#attributemapping-1)
|
|
266
265
|
* [type](#type-1)
|
|
266
|
+
* [homePageURL](#homepageurl-1)
|
|
267
267
|
* [RepositoryOwner](#repositoryowner)
|
|
268
268
|
* [Parameters](#parameters-57)
|
|
269
269
|
* [Repository](#repository-3)
|
|
@@ -480,23 +480,23 @@ Filters out null, undefined and empty strings
|
|
|
480
480
|
|
|
481
481
|
Returns **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** keys renamed after mapping
|
|
482
482
|
|
|
483
|
-
## description
|
|
483
|
+
## description\_attribute
|
|
484
484
|
|
|
485
485
|
The description of the object content.
|
|
486
486
|
|
|
487
|
-
## id
|
|
487
|
+
## id\_attribute
|
|
488
488
|
|
|
489
489
|
Unique id within the provider.
|
|
490
490
|
|
|
491
|
-
## body
|
|
491
|
+
## body\_attribute
|
|
492
492
|
|
|
493
493
|
The description of the pull request.
|
|
494
494
|
|
|
495
|
-
## title
|
|
495
|
+
## title\_attribute
|
|
496
496
|
|
|
497
497
|
The one line description of the pull request.
|
|
498
498
|
|
|
499
|
-
## priority
|
|
499
|
+
## priority\_attribute
|
|
500
500
|
|
|
501
501
|
In case there are several providers able to support a given source which one sould be used ?
|
|
502
502
|
this defines the order
|
|
@@ -1113,12 +1113,6 @@ Provided name and all defined attributes.
|
|
|
1113
1113
|
|
|
1114
1114
|
options
|
|
1115
1115
|
|
|
1116
|
-
## homePageURL
|
|
1117
|
-
|
|
1118
|
-
The url of home page.
|
|
1119
|
-
|
|
1120
|
-
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
1121
|
-
|
|
1122
1116
|
## OwnedObject
|
|
1123
1117
|
|
|
1124
1118
|
**Extends NamedObject**
|
|
@@ -1559,6 +1553,12 @@ Map attributes between external and internal representation.
|
|
|
1559
1553
|
|
|
1560
1554
|
Type of the repository group either User or Organization.
|
|
1561
1555
|
|
|
1556
|
+
## homePageURL
|
|
1557
|
+
|
|
1558
|
+
The url of home page.
|
|
1559
|
+
|
|
1560
|
+
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
1561
|
+
|
|
1562
1562
|
## RepositoryOwner
|
|
1563
1563
|
|
|
1564
1564
|
Mixin to define a class able to handle a collection of repositories.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "repository-provider",
|
|
3
|
-
"version": "32.4.
|
|
3
|
+
"version": "32.4.9",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"ava": "^5.1.0",
|
|
38
|
-
"browser-ava": "^1.3.
|
|
38
|
+
"browser-ava": "^1.3.14",
|
|
39
39
|
"c8": "^7.12.0",
|
|
40
40
|
"documentation": "^14.0.1",
|
|
41
41
|
"repository-provider-test-support": "^2.2.30",
|
package/src/base-object.mjs
CHANGED
package/src/owned-object.mjs
CHANGED
|
@@ -13,6 +13,11 @@ export class OwnedObject extends NamedObject {
|
|
|
13
13
|
return "_add" + this.name;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
+
/**
|
|
17
|
+
* Method name to be called to unregister one instance in the owner.
|
|
18
|
+
* sample: Application => _deleteApplication
|
|
19
|
+
* @return {string}
|
|
20
|
+
*/
|
|
16
21
|
static get deleteMethodName() {
|
|
17
22
|
return "_delete" + this.name;
|
|
18
23
|
}
|
package/src/ref.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OwnedObject } from "./owned-object.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { boolean_attribute } from "./attributes.mjs";
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* @typedef {Object} ContentEntry
|
|
@@ -22,7 +22,7 @@ export class Ref extends OwnedObject {
|
|
|
22
22
|
* Can the ref be modified.
|
|
23
23
|
* @return {string}
|
|
24
24
|
*/
|
|
25
|
-
isProtected:
|
|
25
|
+
isProtected: boolean_attribute
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
28
|
|
package/src/repository-owner.mjs
CHANGED
|
@@ -42,13 +42,10 @@ export function RepositoryOwner(base) {
|
|
|
42
42
|
* @return {Promise<Repository>}
|
|
43
43
|
*/
|
|
44
44
|
async repository(name) {
|
|
45
|
-
if (name
|
|
46
|
-
|
|
45
|
+
if (name !== undefined) {
|
|
46
|
+
await this.initializeRepositories();
|
|
47
|
+
return this.#repositories.get(this.normalizeRepositoryName(name, true));
|
|
47
48
|
}
|
|
48
|
-
|
|
49
|
-
await this.initializeRepositories();
|
|
50
|
-
|
|
51
|
-
return this.#repositories.get(this.normalizeRepositoryName(name, true));
|
|
52
49
|
}
|
|
53
50
|
|
|
54
51
|
/**
|
|
@@ -162,7 +159,7 @@ export function RepositoryOwner(base) {
|
|
|
162
159
|
* @return {Promise<Repository>} newly created repository
|
|
163
160
|
*/
|
|
164
161
|
addRepository(name, options) {
|
|
165
|
-
return this.#repositories.get(this.normalizeRepositoryName(name, true)) ||
|
|
162
|
+
return this.#repositories.get(this.normalizeRepositoryName(name, true)) || new this.repositoryClass(this, name, options);
|
|
166
163
|
}
|
|
167
164
|
|
|
168
165
|
_addRepository(repository)
|