mirror of
https://github.com/jagandeepbrar/lunasea.git
synced 2026-08-31 12:42:34 +00:00
(feat): Implemented Overseerr core architecture, Added platform checks for Firebase, Added module flagging (#425)
This commit is contained in:
@@ -6,7 +6,9 @@ import 'package:lunasea/core.dart';
|
||||
|
||||
class LunaFirebaseAnalytics {
|
||||
/// Returns true if Firebase Analytics is compatible with this build system/platform.
|
||||
static bool get isPlatformCompatible => !Platform.isLinux && !Platform.isMacOS && !Platform.isWindows;
|
||||
static bool get isPlatformCompatible {
|
||||
return LunaFirebase.isPlatformCompatible && !Platform.isLinux && !Platform.isMacOS && !Platform.isWindows;
|
||||
}
|
||||
|
||||
/// Returns an instance of [FirebaseAnalytics].
|
||||
///
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:firebase_core/firebase_core.dart';
|
||||
|
||||
class LunaFirebase {
|
||||
@@ -6,6 +8,9 @@ class LunaFirebase {
|
||||
/// Throws an error if [LunaFirebase.initialize] has not been called.
|
||||
static FirebaseApp get instance => Firebase.app();
|
||||
|
||||
/// Returns true if Firebase in its entirety is compatible with this build system/platform.
|
||||
static bool get isPlatformCompatible => Platform.isIOS || Platform.isAndroid || Platform.isMacOS;
|
||||
|
||||
/// Initialize Firebase and configuration.
|
||||
///
|
||||
/// This must be called before anything accesses Firebase services, or an exception will be thrown.
|
||||
|
||||
@@ -5,7 +5,9 @@ import 'package:lunasea/core.dart';
|
||||
|
||||
class LunaFirebaseCrashlytics {
|
||||
/// Returns true if Firebase Analytics is compatible with this build system/platform.
|
||||
static bool get isPlatformCompatible => !Platform.isLinux && !Platform.isMacOS && !Platform.isWindows;
|
||||
static bool get isPlatformCompatible {
|
||||
return LunaFirebase.isPlatformCompatible && !Platform.isLinux && !Platform.isMacOS && !Platform.isWindows;
|
||||
}
|
||||
|
||||
/// Returns an instance of [FirebaseCrashlytics].
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user