@nocobase/acl 1.4.9 → 1.4.10

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.
Files changed (2) hide show
  1. package/lib/acl.js +4 -0
  2. package/package.json +4 -4
package/lib/acl.js CHANGED
@@ -371,6 +371,7 @@ const _ACL = class _ACL extends import_events.default {
371
371
  }
372
372
  }
373
373
  }
374
+ const isEmptyFields = resourcerAction.params.fields && resourcerAction.params.fields.length === 0;
374
375
  resourcerAction.mergeParams(parsedParams, {
375
376
  appends: /* @__PURE__ */ __name((x, y) => {
376
377
  if (!x) {
@@ -382,6 +383,9 @@ const _ACL = class _ACL extends import_events.default {
382
383
  return x.filter((i) => y.includes(i.split(".").shift()));
383
384
  }, "appends")
384
385
  });
386
+ if (isEmptyFields) {
387
+ resourcerAction.params.fields = [];
388
+ }
385
389
  ctx.permission.mergedParams = import_lodash.default.cloneDeep(resourcerAction.params);
386
390
  }
387
391
  } catch (e) {
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@nocobase/acl",
3
- "version": "1.4.9",
3
+ "version": "1.4.10",
4
4
  "description": "",
5
5
  "license": "AGPL-3.0",
6
6
  "main": "./lib/index.js",
7
7
  "types": "./lib/index.d.ts",
8
8
  "dependencies": {
9
- "@nocobase/resourcer": "1.4.9",
10
- "@nocobase/utils": "1.4.9",
9
+ "@nocobase/resourcer": "1.4.10",
10
+ "@nocobase/utils": "1.4.10",
11
11
  "minimatch": "^5.1.1"
12
12
  },
13
13
  "repository": {
@@ -15,5 +15,5 @@
15
15
  "url": "git+https://github.com/nocobase/nocobase.git",
16
16
  "directory": "packages/acl"
17
17
  },
18
- "gitHead": "1e1bc9152bd72a251f6f68e046be1ee68dda9bd2"
18
+ "gitHead": "24ae34685506e34f254c44c25eb50e253ea0c2b6"
19
19
  }