feat: set presence in sync
This commit is contained in:
parent
f85ef5ed60
commit
88888a43f1
|
|
@ -797,6 +797,9 @@ class Client extends MatrixApi {
|
||||||
return _currentSync;
|
return _currentSync;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Presence that is set on sync.
|
||||||
|
PresenceType syncPresence;
|
||||||
|
|
||||||
Future<void> _innerSync() async {
|
Future<void> _innerSync() async {
|
||||||
await _retryDelay;
|
await _retryDelay;
|
||||||
_retryDelay = Future.delayed(Duration(seconds: syncErrorTimeoutSec));
|
_retryDelay = Future.delayed(Duration(seconds: syncErrorTimeoutSec));
|
||||||
|
|
@ -806,6 +809,7 @@ class Client extends MatrixApi {
|
||||||
filter: syncFilters,
|
filter: syncFilters,
|
||||||
since: prevBatch,
|
since: prevBatch,
|
||||||
timeout: prevBatch != null ? 30000 : null,
|
timeout: prevBatch != null ? 30000 : null,
|
||||||
|
setPresence: syncPresence,
|
||||||
);
|
);
|
||||||
if (_disposed) return;
|
if (_disposed) return;
|
||||||
if (database != null) {
|
if (database != null) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue