mirror of
https://github.com/inventree/inventree-app.git
synced 2025-06-12 02:05:29 +00:00
Remove all sentry references
- Google play store already offers crash reporting...
This commit is contained in:
@ -1,7 +1,3 @@
|
||||
import 'dart:async';
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:InvenTree/inventree/sentry.dart';
|
||||
import 'package:flutter_localizations/flutter_localizations.dart';
|
||||
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
|
||||
|
||||
@ -10,42 +6,11 @@ import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:one_context/one_context.dart';
|
||||
|
||||
import 'dsn.dart';
|
||||
|
||||
import 'package:sentry_flutter/sentry_flutter.dart';
|
||||
|
||||
|
||||
void main() async {
|
||||
|
||||
|
||||
await Sentry.init((options) {
|
||||
options.dsn = SENTRY_DSN_KEY;
|
||||
},
|
||||
//appRunner: () => runApp(InvenTreeApp())
|
||||
);
|
||||
|
||||
await runZonedGuarded<Future<void>>(() async {
|
||||
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
|
||||
// This captures errors reported by the Flutter framework.
|
||||
FlutterError.onError = (FlutterErrorDetails details) async {
|
||||
if (isInDebugMode()) {
|
||||
// In development mode simply print to console.
|
||||
FlutterError.dumpErrorToConsole(details);
|
||||
} else {
|
||||
// In production mode report to the application zone to report to
|
||||
// Sentry.
|
||||
Zone.current.handleUncaughtError(details.exception, details.stack);
|
||||
}
|
||||
};
|
||||
|
||||
runApp(InvenTreeApp());
|
||||
|
||||
}, (Object error, StackTrace stackTrace) {
|
||||
sentryReportError(error, stackTrace);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
class InvenTreeApp extends StatelessWidget {
|
||||
|
Reference in New Issue
Block a user