@abtnode/core 1.8.7 → 1.8.8

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.
@@ -2211,6 +2211,9 @@ class BlockletManager extends BaseBlockletManager {
2211
2211
  } else {
2212
2212
  newBlocklet.children.push(newChild);
2213
2213
  }
2214
+
2215
+ checkDuplicateComponents(newBlocklet.children);
2216
+
2214
2217
  await this._upsertDynamicNavigation(newBlocklet.meta.did, newChild);
2215
2218
 
2216
2219
  await this._downloadBlocklet(newBlocklet, oldBlocklet);
@@ -21,6 +21,7 @@ const CustomError = require('@abtnode/util/lib/custom-error');
21
21
  const getFolderSize = require('@abtnode/util/lib/get-folder-size');
22
22
  const normalizePathPrefix = require('@abtnode/util/lib/normalize-path-prefix');
23
23
  const hashFiles = require('@abtnode/util/lib/hash-files');
24
+ const isPathPrefixEqual = require('@abtnode/util/lib/is-path-prefix-equal');
24
25
  const { BLOCKLET_MAX_MEM_LIMIT_IN_MB, BLOCKLET_STORE_API_BLOCKLET_PREFIX } = require('@abtnode/constant');
25
26
 
26
27
  const {
@@ -1191,7 +1192,7 @@ const checkDuplicateComponents = (components = []) => {
1191
1192
  }
1192
1193
 
1193
1194
  const duplicateMountPoints = components.filter(
1194
- (item, index) => components.findIndex((x) => x.mountPoint === item.mountPoint) !== index
1195
+ (item, index) => components.findIndex((x) => isPathPrefixEqual(x.mountPoint, item.mountPoint)) !== index
1195
1196
  );
1196
1197
  if (duplicateMountPoints.length) {
1197
1198
  throw new Error(`mount point must be unique: ${duplicateMountPoints.map((x) => x.mountPoint).join(', ')}`);
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "1.8.7",
6
+ "version": "1.8.8",
7
7
  "description": "",
8
8
  "main": "lib/index.js",
9
9
  "files": [
@@ -19,32 +19,32 @@
19
19
  "author": "wangshijun <wangshijun2010@gmail.com> (http://github.com/wangshijun)",
20
20
  "license": "MIT",
21
21
  "dependencies": {
22
- "@abtnode/certificate-manager": "1.8.7",
23
- "@abtnode/constant": "1.8.7",
24
- "@abtnode/cron": "1.8.7",
25
- "@abtnode/db": "1.8.7",
26
- "@abtnode/logger": "1.8.7",
27
- "@abtnode/queue": "1.8.7",
28
- "@abtnode/rbac": "1.8.7",
29
- "@abtnode/router-provider": "1.8.7",
30
- "@abtnode/static-server": "1.8.7",
31
- "@abtnode/timemachine": "1.8.7",
32
- "@abtnode/util": "1.8.7",
33
- "@arcblock/did": "1.17.10",
22
+ "@abtnode/certificate-manager": "1.8.8",
23
+ "@abtnode/constant": "1.8.8",
24
+ "@abtnode/cron": "1.8.8",
25
+ "@abtnode/db": "1.8.8",
26
+ "@abtnode/logger": "1.8.8",
27
+ "@abtnode/queue": "1.8.8",
28
+ "@abtnode/rbac": "1.8.8",
29
+ "@abtnode/router-provider": "1.8.8",
30
+ "@abtnode/static-server": "1.8.8",
31
+ "@abtnode/timemachine": "1.8.8",
32
+ "@abtnode/util": "1.8.8",
33
+ "@arcblock/did": "1.17.11",
34
34
  "@arcblock/did-motif": "^1.1.10",
35
- "@arcblock/did-util": "1.17.10",
36
- "@arcblock/event-hub": "1.17.10",
37
- "@arcblock/jwt": "^1.17.10",
35
+ "@arcblock/did-util": "1.17.11",
36
+ "@arcblock/event-hub": "1.17.11",
37
+ "@arcblock/jwt": "^1.17.11",
38
38
  "@arcblock/pm2-events": "^0.0.5",
39
- "@arcblock/vc": "1.17.10",
40
- "@blocklet/meta": "1.8.7",
41
- "@blocklet/sdk": "1.8.7",
39
+ "@arcblock/vc": "1.17.11",
40
+ "@blocklet/meta": "1.8.8",
41
+ "@blocklet/sdk": "1.8.8",
42
42
  "@fidm/x509": "^1.2.1",
43
43
  "@nedb/core": "^1.3.2",
44
44
  "@nedb/multi": "^1.3.2",
45
- "@ocap/mcrypto": "1.17.10",
46
- "@ocap/util": "1.17.10",
47
- "@ocap/wallet": "1.17.10",
45
+ "@ocap/mcrypto": "1.17.11",
46
+ "@ocap/util": "1.17.11",
47
+ "@ocap/wallet": "1.17.11",
48
48
  "@slack/webhook": "^5.0.4",
49
49
  "axios": "^0.27.2",
50
50
  "axon": "^2.0.3",
@@ -82,5 +82,5 @@
82
82
  "express": "^4.18.1",
83
83
  "jest": "^27.5.1"
84
84
  },
85
- "gitHead": "9807ea28b3ae634f5806c875774ac3b7e38502a1"
85
+ "gitHead": "8da61db2342d7c53f2b803e5193c03d82bce8f77"
86
86
  }