Merge branch 'krille/get-timeline-exception' into 'main'

fix: Capture getTimeline exceptions

See merge request famedly/fluffychat!572
This commit is contained in:
Krille Fear 2021-11-23 11:29:12 +00:00
commit dfb8b47433
2 changed files with 9 additions and 2 deletions

View File

@ -18,6 +18,7 @@ import 'package:fluffychat/pages/chat/tombstone_display.dart';
import 'package:fluffychat/pages/chat/typing_indicators.dart';
import 'package:fluffychat/pages/user_bottom_sheet/user_bottom_sheet.dart';
import 'package:fluffychat/utils/platform_infos.dart';
import 'package:fluffychat/utils/sentry_controller.dart';
import 'package:fluffychat/widgets/chat_settings_popup_menu.dart';
import 'package:fluffychat/widgets/connection_status_header.dart';
import 'package:fluffychat/widgets/matrix.dart';
@ -183,6 +184,12 @@ class ChatView extends StatelessWidget {
child: FutureBuilder<bool>(
future: controller.getTimeline(),
builder: (BuildContext context, snapshot) {
if (snapshot.hasError) {
SentryController.captureException(
snapshot.error,
StackTrace.current,
);
}
if (controller.timeline == null) {
return const Center(
child: CircularProgressIndicator.adaptive(

View File

@ -364,7 +364,7 @@ packages:
name: fluffybox
url: "https://pub.dartlang.org"
source: hosted
version: "0.3.2"
version: "0.3.3"
flutter:
dependency: "direct main"
description: flutter
@ -782,7 +782,7 @@ packages:
description:
path: "."
ref: "krille/idb"
resolved-ref: "1714f0a35f2558a6fb56bdf6940cf2a13cdcd5dd"
resolved-ref: "44f55826c95e4d0c8d5a0485661a58e7d42d3560"
url: "https://gitlab.com/famedly/company/frontend/famedlysdk.git"
source: git
version: "0.7.0-nullsafety.6"