mirror of
https://github.com/status-im/realm-js.git
synced 2025-01-26 22:39:05 +00:00
Clarifying PermissionCondition. (#1637)
This commit is contained in:
parent
ae8e50fc36
commit
f9e8161017
@ -8,6 +8,7 @@ X.Y.Z Release notes
|
||||
|
||||
### Bug fixes
|
||||
* [Object Server] Fixed a typing error leading to `_getExistingUser` wasn't defined in the Chrome debugging support library (#1625).
|
||||
* Fixed a bug in the TypeScript definition of `PermissionCondition` (#1574).
|
||||
* [Electron] Fixed a `dlopen` error related to OpenSSL that prevented using realm-js on Linux (#1636).
|
||||
|
||||
### Internal
|
||||
|
13
lib/index.d.ts
vendored
13
lib/index.d.ts
vendored
@ -303,9 +303,16 @@ declare namespace Realm.Sync {
|
||||
invalidatePermissionOffer(permissionOfferOrToken: PermissionOffer | string): Promise<void>;
|
||||
}
|
||||
|
||||
type PermissionCondition = {
|
||||
userId: string | { metadataKey: string, metadataValue: string }
|
||||
};
|
||||
interface _PermissionConditionUserId {
|
||||
userId: string
|
||||
}
|
||||
|
||||
interface _PermissionConditionMetadata {
|
||||
metadataKey: string
|
||||
metadataValue: string
|
||||
}
|
||||
|
||||
type PermissionCondition = _PermissionConditionUserId | _PermissionConditionMetadata
|
||||
|
||||
type AccessLevel = 'none' | 'read' | 'write' | 'admin';
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user