You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,16 +1,18 @@
1
1
## vNext (TBD)
2
2
3
3
### Enhancements
4
-
* None
4
+
* Added `User.changes` stream that allows subscribers to receive notifications when the User changes - for example when the user's custom data changes or when their authentication state changes. (PR [#1500](https://github.com/realm/realm-dart/pull/1500))
5
+
* Allow the query builder to construct >, >=, <, <= queries for string constants. This is a case sensitive lexicographical comparison. Improved performance of RQL queries on a non-linked string property using: >, >=, <, <=, operators and fixed behaviour that a null string should be evaulated as less than everything, previously nulls were not matched. (Core 13.26.0-13-gd12c3)
5
6
6
7
### Fixed
7
8
* Creating an `AppConfiguration` with an empty appId will now throw an exception rather than crashing the app. (Issue [#1487](https://github.com/realm/realm-dart/issues/1487))
9
+
* Uploading the changesets recovered during an automatic client reset recovery may lead to 'Bad server version' errors and a new client reset. (Core 13.26.0-13-gd12c3)
/// Describes the changes to a [User] instance - for example when the access token is updated or the user state changes.
28
+
/// Right now, this only conveys information that the user has changed, but in the future it will be enhanced by adding
29
+
/// details about the exact properties that have been updated.
30
+
classUserChanges {
31
+
/// The user that has changed.
32
+
finalUser user;
33
+
34
+
constUserChanges._(this.user);
35
+
}
36
+
25
37
/// This class represents a `user` in an [Atlas App Services](https://www.mongodb.com/docs/atlas/app-services/) application.
26
38
/// A user can log in to the server and, if access is granted, it is possible to synchronize the local Realm to MongoDB Atlas.
27
39
/// Moreover, synchronization is halted when the user is logged out. It is possible to persist a user. By retrieving a user, there is no need to log in again.
@@ -161,6 +173,55 @@ class User {
161
173
throwRealmError('User must be logged in to $clarification');
162
174
}
163
175
}
176
+
177
+
/// Gets a [Stream] of [UserChanges] that can be used to receive notifications when the user changes.
178
+
Stream<UserChanges> get changes {
179
+
final controller =UserNotificationsController(this);
0 commit comments