chore: Update sdk
This commit is contained in:
parent
c221e497bb
commit
87737705ff
|
@ -244,7 +244,7 @@ class MatrixState extends State<Matrix> {
|
||||||
});
|
});
|
||||||
onJitsiCallSub ??= client.onEvent.stream
|
onJitsiCallSub ??= client.onEvent.stream
|
||||||
.where((e) =>
|
.where((e) =>
|
||||||
e.type == 'timeline' &&
|
e.type == EventUpdateType.timeline &&
|
||||||
e.eventType == 'm.room.message' &&
|
e.eventType == 'm.room.message' &&
|
||||||
e.content['content']['msgtype'] == Matrix.callNamespace &&
|
e.content['content']['msgtype'] == Matrix.callNamespace &&
|
||||||
e.content['sender'] != client.userID)
|
e.content['sender'] != client.userID)
|
||||||
|
@ -313,7 +313,7 @@ class MatrixState extends State<Matrix> {
|
||||||
html.Notification.requestPermission();
|
html.Notification.requestPermission();
|
||||||
onNotification ??= client.onEvent.stream
|
onNotification ??= client.onEvent.stream
|
||||||
.where((e) =>
|
.where((e) =>
|
||||||
e.type == 'timeline' &&
|
e.type == EventUpdateType.timeline &&
|
||||||
[EventTypes.Message, EventTypes.Sticker, EventTypes.Encrypted]
|
[EventTypes.Message, EventTypes.Sticker, EventTypes.Encrypted]
|
||||||
.contains(e.eventType) &&
|
.contains(e.eventType) &&
|
||||||
e.content['sender'] != client.userID)
|
e.content['sender'] != client.userID)
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import 'dart:math';
|
import 'dart:math';
|
||||||
|
|
||||||
|
import 'package:famedlysdk/famedlysdk.dart';
|
||||||
import 'package:fluffychat/components/dialogs/simple_dialogs.dart';
|
import 'package:fluffychat/components/dialogs/simple_dialogs.dart';
|
||||||
import 'package:fluffychat/components/matrix.dart';
|
import 'package:fluffychat/components/matrix.dart';
|
||||||
import 'package:fluffychat/config/app_config.dart';
|
import 'package:fluffychat/config/app_config.dart';
|
||||||
|
@ -31,12 +32,17 @@ class HomeserverPicker extends StatelessWidget {
|
||||||
}
|
}
|
||||||
|
|
||||||
final success = await SimpleDialogs(context).tryRequestWithLoadingDialog(
|
final success = await SimpleDialogs(context).tryRequestWithLoadingDialog(
|
||||||
Matrix.of(context).client.checkServer(homeserver));
|
checkHomeserver(homeserver, Matrix.of(context).client));
|
||||||
if (success != false) {
|
if (success == true) {
|
||||||
await Navigator.of(context).push(AppRoute(SignUp()));
|
await Navigator.of(context).push(AppRoute(SignUp()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<bool> checkHomeserver(dynamic homeserver, Client client) async {
|
||||||
|
await client.checkHomeserver(homeserver);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
|
|
|
@ -94,7 +94,7 @@ class _LoginState extends State<Login> {
|
||||||
if ((newDomain?.isNotEmpty ?? false) &&
|
if ((newDomain?.isNotEmpty ?? false) &&
|
||||||
newDomain != Matrix.of(context).client.homeserver.toString()) {
|
newDomain != Matrix.of(context).client.homeserver.toString()) {
|
||||||
await SimpleDialogs(context).tryRequestWithErrorToast(
|
await SimpleDialogs(context).tryRequestWithErrorToast(
|
||||||
Matrix.of(context).client.checkServer(newDomain));
|
Matrix.of(context).client.checkHomeserver(newDomain));
|
||||||
setState(() => usernameError = null);
|
setState(() => usernameError = null);
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
@ -208,8 +208,8 @@ packages:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
path: "."
|
path: "."
|
||||||
ref: be6824b7465b2bda7e5b769254be5cddd207b479
|
ref: "412da6ae0cf3aa8139a29381c4f07910d541deab"
|
||||||
resolved-ref: be6824b7465b2bda7e5b769254be5cddd207b479
|
resolved-ref: "412da6ae0cf3aa8139a29381c4f07910d541deab"
|
||||||
url: "https://gitlab.com/famedly/famedlysdk.git"
|
url: "https://gitlab.com/famedly/famedlysdk.git"
|
||||||
source: git
|
source: git
|
||||||
version: "0.0.1"
|
version: "0.0.1"
|
||||||
|
|
|
@ -27,7 +27,7 @@ dependencies:
|
||||||
famedlysdk:
|
famedlysdk:
|
||||||
git:
|
git:
|
||||||
url: https://gitlab.com/famedly/famedlysdk.git
|
url: https://gitlab.com/famedly/famedlysdk.git
|
||||||
ref: be6824b7465b2bda7e5b769254be5cddd207b479
|
ref: 412da6ae0cf3aa8139a29381c4f07910d541deab
|
||||||
|
|
||||||
localstorage: ^3.0.1+4
|
localstorage: ^3.0.1+4
|
||||||
file_picker_cross: ^4.2.2
|
file_picker_cross: ^4.2.2
|
||||||
|
|
Loading…
Reference in a new issue