@steedos/standard-permission 2.4.0-beta.36 → 2.4.0-beta.37

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.
@@ -49,7 +49,7 @@ async function checkMultiple(permission_set, tab, action, id) {
49
49
  if (!permission_set || !tab) return
50
50
 
51
51
  const pTabObj = objectql.getObject('permission_tabs')
52
- const pTabDocs = await pTabObj.find({
52
+ const pTabDocs = await pTabObj.directFind({
53
53
  filters: [
54
54
  ['permission_set', '=', permission_set],
55
55
  ['tab', '=', tab]
@@ -70,7 +70,8 @@ module.exports = {
70
70
 
71
71
  beforeInsert: async function () {
72
72
  const { doc, id } = this
73
- await checkMultiple(doc.permission_set, doc.tab, 'beforeInsert', id)
73
+
74
+ await checkMultiple(doc.permission_set, doc.tab, 'beforeInsert', null)
74
75
  },
75
76
 
76
77
  beforeUpdate: async function () {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@steedos/standard-permission",
3
- "version": "2.4.0-beta.36",
3
+ "version": "2.4.0-beta.37",
4
4
  "main": "package.service.js",
5
5
  "private": false,
6
6
  "publishConfig": {
@@ -12,5 +12,5 @@
12
12
  "description": "steedos package",
13
13
  "repository": {},
14
14
  "license": "MIT",
15
- "gitHead": "63a5f08e0c5ef01c92e08591178282e5c6e7b389"
15
+ "gitHead": "3fe675c2fb030976c7e43729b754ce772c07d8e8"
16
16
  }