@openinc/parse-server-opendash 1.13.0 → 1.13.1

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.
@@ -37,11 +37,13 @@ async function init() {
37
37
  request.context.tenantChanged = true;
38
38
  }
39
39
  // fetch user groups
40
- const groups = await new Parse.Query(types_1.Group)
41
- .equalTo("users", user)
42
- .equalTo("usersSeeEachOther", true)
43
- .limit(1000000)
44
- .find({ useMasterKey: true });
40
+ const groups = user.id
41
+ ? await new Parse.Query(types_1.Group)
42
+ .equalTo("users", user)
43
+ .equalTo("usersSeeEachOther", true)
44
+ .limit(1000000)
45
+ .find({ useMasterKey: true })
46
+ : [];
45
47
  user.setACL(new Parse.ACL({
46
48
  ...(tenantId && {
47
49
  [`role:od-tenant-user-${tenantId}`]: { read: true },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openinc/parse-server-opendash",
3
- "version": "1.13.0",
3
+ "version": "1.13.1",
4
4
  "description": "Parse Server Cloud Code for open.DASH",
5
5
  "keywords": [
6
6
  "parse",