@@ -478,12 +478,8 @@ class MainScaffold extends StatelessWidget {
478
478
TooltipButton (
479
479
onPressed: () async {
480
480
final id = await Sentry .captureMessage ('UserFeedback' );
481
- // ignore: use_build_context_synchronously
482
- if (! context.isMounted) {
483
- return ;
484
- }
485
481
486
- // ignore: use_build_context_synchronously
482
+ if ( ! context.mounted) return ;
487
483
await showDialog (
488
484
context: context,
489
485
builder: (context) {
@@ -906,12 +902,7 @@ Future<void> makeWebRequest(BuildContext context) async {
906
902
907
903
await transaction.finish (status: const SpanStatus .ok ());
908
904
909
- // ignore: use_build_context_synchronously
910
- if (! context.isMounted) {
911
- return ;
912
- }
913
-
914
- // ignore: use_build_context_synchronously
905
+ if (! context.mounted) return ;
915
906
await showDialog <void >(
916
907
context: context,
917
908
builder: (context) {
@@ -957,12 +948,7 @@ Future<void> makeWebRequestWithDio(BuildContext context) async {
957
948
await span.finish ();
958
949
}
959
950
960
- // ignore: use_build_context_synchronously
961
- if (! context.isMounted) {
962
- return ;
963
- }
964
-
965
- // ignore: use_build_context_synchronously
951
+ if (! context.mounted) return ;
966
952
await showDialog <void >(
967
953
context: context,
968
954
builder: (context) {
@@ -992,12 +978,7 @@ Future<void> showDialogWithTextAndImage(BuildContext context) async {
992
978
final text =
993
979
await DefaultAssetBundle .of (context).loadString ('assets/lorem-ipsum.txt' );
994
980
995
- // ignore: use_build_context_synchronously
996
- if (! context.isMounted) {
997
- return ;
998
- }
999
-
1000
- // ignore: use_build_context_synchronously
981
+ if (! context.mounted) return ;
1001
982
await showDialog <void >(
1002
983
context: context,
1003
984
// gets tracked if using SentryNavigatorObserver
0 commit comments