File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 1
1
import 'package:flutter/material.dart' ;
2
2
import 'dart:async' ;
3
-
3
+ import 'dart:io' show Platform;
4
4
import 'package:flutter/services.dart' ;
5
5
import 'package:instabug_flutter/instabug_flutter.dart' ;
6
6
@@ -25,11 +25,12 @@ class _MyAppState extends State<MyApp> {
25
25
String platformVersion;
26
26
// Platform messages may fail, so we use a try/catch PlatformException.
27
27
try {
28
- InstabugFlutter .start ('9582e6cfe34e2b8897f48cfa3b617adb' , [InvocationEvent .floatingButton, InvocationEvent .shake]);
28
+ if (Platform .isIOS) {
29
+ InstabugFlutter .start ('9582e6cfe34e2b8897f48cfa3b617adb' , [InvocationEvent .floatingButton, InvocationEvent .shake]);
30
+ }
29
31
} on PlatformException {
30
32
platformVersion = 'Failed to get platform version.' ;
31
33
}
32
-
33
34
// If the widget was removed from the tree while the asynchronous platform
34
35
// message was in flight, we want to discard the reply rather than calling
35
36
// setState to update our non-existent appearance.
You can’t perform that action at this time.
0 commit comments