jazz-tools 0.13.25 → 0.13.26
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/.turbo/turbo-build.log +5 -5
- package/CHANGELOG.md +6 -0
- package/dist/{chunk-Z6IXFGH3.js → chunk-E4PALNK7.js} +4 -5
- package/dist/chunk-E4PALNK7.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/subscribe/utils.d.ts.map +1 -1
- package/dist/testing.js +1 -1
- package/package.json +1 -1
- package/src/subscribe/SubscriptionScope.ts +3 -3
- package/src/subscribe/utils.ts +3 -3
- package/src/tests/account.test.ts +42 -1
- package/dist/chunk-Z6IXFGH3.js.map +0 -1
package/.turbo/turbo-build.log
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
|
2
|
-
> jazz-tools@0.13.
|
2
|
+
> jazz-tools@0.13.26 build /home/runner/_work/jazz/jazz/packages/jazz-tools
|
3
3
|
> tsup && pnpm types
|
4
4
|
|
5
5
|
[34mCLI[39m Building entry: {"index":"src/index.ts","testing":"src/testing.ts"}
|
@@ -11,12 +11,12 @@
|
|
11
11
|
[34mESM[39m Build start
|
12
12
|
[32mESM[39m [1mdist/index.js [22m[32m1.48 KB[39m
|
13
13
|
[32mESM[39m [1mdist/testing.js [22m[32m6.27 KB[39m
|
14
|
-
[32mESM[39m [1mdist/chunk-
|
14
|
+
[32mESM[39m [1mdist/chunk-E4PALNK7.js [22m[32m122.85 KB[39m
|
15
15
|
[32mESM[39m [1mdist/index.js.map [22m[32m258.00 B[39m
|
16
16
|
[32mESM[39m [1mdist/testing.js.map [22m[32m12.38 KB[39m
|
17
|
-
[32mESM[39m [1mdist/chunk-
|
18
|
-
[32mESM[39m ⚡️ Build success in
|
17
|
+
[32mESM[39m [1mdist/chunk-E4PALNK7.js.map [22m[32m281.45 KB[39m
|
18
|
+
[32mESM[39m ⚡️ Build success in 57ms
|
19
19
|
|
20
|
-
> jazz-tools@0.13.
|
20
|
+
> jazz-tools@0.13.26 types /home/runner/_work/jazz/jazz/packages/jazz-tools
|
21
21
|
> tsc --outDir dist
|
22
22
|
|
package/CHANGELOG.md
CHANGED
@@ -136,7 +136,7 @@ var JazzError = class _JazzError {
|
|
136
136
|
};
|
137
137
|
|
138
138
|
// src/subscribe/utils.ts
|
139
|
-
import { RawAccount
|
139
|
+
import { RawAccount } from "cojson";
|
140
140
|
|
141
141
|
// src/coValues/registeredSchemas.ts
|
142
142
|
var RegisteredSchemas = {};
|
@@ -157,7 +157,7 @@ var coValuesCache = {
|
|
157
157
|
|
158
158
|
// src/subscribe/utils.ts
|
159
159
|
function getOwnerFromRawValue(raw) {
|
160
|
-
|
160
|
+
const owner = raw.group;
|
161
161
|
return coValuesCache.get(
|
162
162
|
owner,
|
163
163
|
() => owner instanceof RawAccount ? RegisteredSchemas["Account"].fromRaw(owner) : RegisteredSchemas["Group"].fromRaw(owner)
|
@@ -245,9 +245,8 @@ var SubscriptionScope = class _SubscriptionScope {
|
|
245
245
|
this.triggerUpdate();
|
246
246
|
return;
|
247
247
|
}
|
248
|
-
const owner = getOwnerFromRawValue(update);
|
249
248
|
const ruleset = update.core.verified.header.ruleset;
|
250
|
-
const hasAccess = ruleset.type
|
249
|
+
const hasAccess = ruleset.type !== "ownedByGroup" || getOwnerFromRawValue(update).myRole() !== void 0;
|
251
250
|
if (!hasAccess) {
|
252
251
|
if (this.value.type !== "unauthorized") {
|
253
252
|
this.updateValue(
|
@@ -4274,4 +4273,4 @@ export {
|
|
4274
4273
|
consumeInviteLink
|
4275
4274
|
};
|
4276
4275
|
/* istanbul ignore file -- @preserve */
|
4277
|
-
//# sourceMappingURL=chunk-
|
4276
|
+
//# sourceMappingURL=chunk-E4PALNK7.js.map
|