@rpcbase/server 0.289.0 → 0.291.0
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.
package/boot/shared.js
CHANGED
package/package.json
CHANGED
|
@@ -64,7 +64,7 @@ const check_apply_permissions = (ac_config, model_name, operation, user_id, item
|
|
|
64
64
|
else if (operation === "update") {
|
|
65
65
|
const doc = item
|
|
66
66
|
if (rule_target === "owner") {
|
|
67
|
-
if (!doc._owners
|
|
67
|
+
if (!doc._owners?.includes(user_id)) {
|
|
68
68
|
// TODO: add debug logging
|
|
69
69
|
return new Error("expected user_id to be in owners to update document")
|
|
70
70
|
}
|