adapt-authoring-content 1.2.0 → 1.2.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.
|
@@ -3,10 +3,16 @@ on:
|
|
|
3
3
|
push:
|
|
4
4
|
branches:
|
|
5
5
|
- master
|
|
6
|
+
|
|
6
7
|
jobs:
|
|
7
8
|
release:
|
|
8
9
|
name: Release
|
|
9
10
|
runs-on: ubuntu-latest
|
|
11
|
+
permissions:
|
|
12
|
+
contents: write # to be able to publish a GitHub release
|
|
13
|
+
issues: write # to be able to comment on released issues
|
|
14
|
+
pull-requests: write # to be able to comment on released pull requests
|
|
15
|
+
id-token: write # to enable use of OIDC for trusted publishing and npm provenance
|
|
10
16
|
steps:
|
|
11
17
|
- name: Checkout
|
|
12
18
|
uses: actions/checkout@v3
|
|
@@ -16,10 +22,11 @@ jobs:
|
|
|
16
22
|
uses: actions/setup-node@v3
|
|
17
23
|
with:
|
|
18
24
|
node-version: 'lts/*'
|
|
25
|
+
- name: Update npm
|
|
26
|
+
run: npm install -g npm@latest
|
|
19
27
|
- name: Install dependencies
|
|
20
28
|
run: npm ci
|
|
21
29
|
- name: Release
|
|
22
30
|
env:
|
|
23
31
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
24
|
-
|
|
25
|
-
run: npx semantic-release
|
|
32
|
+
run: npx semantic-release
|
package/lib/ContentModule.js
CHANGED
|
@@ -248,7 +248,7 @@ class ContentModule extends AbstractApiModule {
|
|
|
248
248
|
throw this.app.errors.NOT_FOUND
|
|
249
249
|
.setData({ type: originalDoc?._type, id: _id })
|
|
250
250
|
}
|
|
251
|
-
if (options.invokePreHook) await this.preCloneHook.invoke(originalDoc)
|
|
251
|
+
if (options.invokePreHook !== false) await this.preCloneHook.invoke(originalDoc)
|
|
252
252
|
|
|
253
253
|
const [parent] = _parentId ? await this.find({ _id: _parentId }) : []
|
|
254
254
|
|
|
@@ -281,7 +281,7 @@ class ContentModule extends AbstractApiModule {
|
|
|
281
281
|
for (let i = 0; i < children.length; i++) {
|
|
282
282
|
await this.clone(userId, children[i]._id, newData._id)
|
|
283
283
|
}
|
|
284
|
-
if (options.invokePostHook) await this.postCloneHook.invoke(originalDoc, newData)
|
|
284
|
+
if (options.invokePostHook !== false) await this.postCloneHook.invoke(originalDoc, newData)
|
|
285
285
|
|
|
286
286
|
return newData
|
|
287
287
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "adapt-authoring-content",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.2",
|
|
4
4
|
"description": "Module for managing Adapt content",
|
|
5
5
|
"homepage": "https://github.com/adapt-security/adapt-authoring-content",
|
|
6
6
|
"license": "GPL-3.0",
|
|
@@ -8,15 +8,15 @@
|
|
|
8
8
|
"main": "index.js",
|
|
9
9
|
"repository": "github:adapt-security/adapt-authoring-content",
|
|
10
10
|
"devDependencies": {
|
|
11
|
-
"
|
|
12
|
-
"@semantic-release/commit-analyzer": "^9.0.2",
|
|
11
|
+
"@semantic-release/commit-analyzer": "^13.0.1",
|
|
13
12
|
"@semantic-release/git": "^10.0.1",
|
|
14
|
-
"@semantic-release/github": "^
|
|
15
|
-
"@semantic-release/npm": "^
|
|
16
|
-
"@semantic-release/release-notes-generator": "^
|
|
17
|
-
"conventional-changelog-eslint": "^
|
|
18
|
-
"semantic-release": "^
|
|
19
|
-
"semantic-release-replace-plugin": "^1.2.7"
|
|
13
|
+
"@semantic-release/github": "^12.0.2",
|
|
14
|
+
"@semantic-release/npm": "^13.1.2",
|
|
15
|
+
"@semantic-release/release-notes-generator": "^14.1.0",
|
|
16
|
+
"conventional-changelog-eslint": "^6.0.0",
|
|
17
|
+
"semantic-release": "^25.0.2",
|
|
18
|
+
"semantic-release-replace-plugin": "^1.2.7",
|
|
19
|
+
"standard": "^17.1.0"
|
|
20
20
|
},
|
|
21
21
|
"release": {
|
|
22
22
|
"plugins": [
|