mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-06 20:19:30 +01:00
chore: Support new unifiedpush gateway discovery
This commit is contained in:
parent
5962f386f6
commit
9e96135ad6
@ -346,7 +346,9 @@ class BackgroundPush {
|
|||||||
.first;
|
.first;
|
||||||
final res =
|
final res =
|
||||||
json.decode(utf8.decode((await http.get(Uri.parse(url))).bodyBytes));
|
json.decode(utf8.decode((await http.get(Uri.parse(url))).bodyBytes));
|
||||||
if (res['gateway'] == 'matrix') {
|
if (res['gateway'] == 'matrix' ||
|
||||||
|
(res['unifiedpush'] is Map &&
|
||||||
|
res['unifiedpush']['gateway'] == 'matrix')) {
|
||||||
endpoint = url;
|
endpoint = url;
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user