@rebasepro/types 0.15.0 → 0.16.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/dist/call_context.d.ts +1 -1
- package/dist/controllers/client.d.ts +1 -1
- package/dist/index.es.js.map +1 -1
- package/dist/types/backend.d.ts +28 -1
- package/dist/types/collections.d.ts +4 -4
- package/dist/types/cron.d.ts +8 -4
- package/dist/types/database_adapter.d.ts +50 -0
- package/dist/types/project_manifest.d.ts +39 -0
- package/dist/types/security_rules.d.ts +8 -8
- package/package.json +1 -1
- package/src/call_context.ts +1 -1
- package/src/controllers/client.ts +1 -1
- package/src/types/backend.ts +35 -1
- package/src/types/collections.ts +4 -4
- package/src/types/cron.ts +8 -4
- package/src/types/database_adapter.ts +57 -0
- package/src/types/project_manifest.ts +39 -0
- package/src/types/security_rules.ts +8 -8
package/dist/call_context.d.ts
CHANGED
|
@@ -64,7 +64,7 @@ export type RebaseCallContext<USER extends User = User> = {
|
|
|
64
64
|
* because RLS filters rather than raises. Write callbacks that tolerate
|
|
65
65
|
* that, or reach for {@link client}`.dataAsAdmin` deliberately when the
|
|
66
66
|
* callback genuinely has to see what an admin may see. Note what that does
|
|
67
|
-
* *not* buy you: `policy.serverContext()` (`
|
|
67
|
+
* *not* buy you: `policy.serverContext()` (`rebase.uid() IS NULL`) is false
|
|
68
68
|
* for the service identity, so a collection whose only rule is
|
|
69
69
|
* `serverContext()` stays closed to it.
|
|
70
70
|
*
|
|
@@ -308,7 +308,7 @@ export interface RebaseClient<DB = unknown> {
|
|
|
308
308
|
*
|
|
309
309
|
* Two consequences the name does not suggest:
|
|
310
310
|
*
|
|
311
|
-
* - `policy.serverContext()` compiles to `
|
|
311
|
+
* - `policy.serverContext()` compiles to `rebase.uid() IS NULL` and is
|
|
312
312
|
* therefore **false** here. A collection with `disableDefaultPolicies:
|
|
313
313
|
* true` whose only rule is `serverContext()` refuses these writes
|
|
314
314
|
* (`42501`) and returns zero rows — HTTP 200, empty — for these reads.
|