mirror of
https://github.com/vodemn/m3_lightmeter.git
synced 2024-11-23 16:00:41 +00:00
6232ad555a
* added crashlytics * added firebase_options to CD * Version bump * added firebase_options to CI * timeout
14 lines
548 B
Dart
14 lines
548 B
Dart
import 'package:firebase_core/firebase_core.dart';
|
|
import 'package:firebase_crashlytics/firebase_crashlytics.dart';
|
|
import 'package:flutter/foundation.dart';
|
|
|
|
import 'firebase_options.dart';
|
|
|
|
Future<void> initializeFirebase() async {
|
|
await Firebase.initializeApp(options: DefaultFirebaseOptions.currentPlatform);
|
|
FlutterError.onError = FirebaseCrashlytics.instance.recordFlutterFatalError;
|
|
PlatformDispatcher.instance.onError = (error, stack) {
|
|
FirebaseCrashlytics.instance.recordError(error, stack, fatal: true);
|
|
return true;
|
|
};
|
|
}
|