update dependencies and general fixes
This commit is contained in:
@@ -33,6 +33,9 @@ Future<void> lazyBootstrap(
|
||||
) async {
|
||||
FlutterNativeSplash.preserve(widgetsBinding: widgetsBinding);
|
||||
if (PlatformUtils.isDesktop) await windowManager.ensureInitialized();
|
||||
|
||||
final sentryLogger = SentryLoggyIntegration();
|
||||
_loggers.addPrinter(sentryLogger);
|
||||
Loggy.initLoggy();
|
||||
|
||||
final appInfo = await AppRepositoryImpl.getAppInfo(env);
|
||||
@@ -45,8 +48,6 @@ Future<void> lazyBootstrap(
|
||||
);
|
||||
|
||||
final enableAnalytics = container.read(enableAnalyticsProvider);
|
||||
final sentryLogger = SentryLoggyIntegration();
|
||||
_loggers.addPrinter(sentryLogger);
|
||||
|
||||
await SentryFlutter.init(
|
||||
(options) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import 'package:accessibility_tools/accessibility_tools.dart';
|
||||
// import 'package:accessibility_tools/accessibility_tools.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_localizations/flutter_localizations.dart';
|
||||
import 'package:hiddify/core/core_providers.dart';
|
||||
|
||||
@@ -29,8 +29,8 @@ class ClashApi with InfraLogger {
|
||||
if (response.statusCode != 200 || response.data == null) {
|
||||
return left(response.statusMessage ?? "");
|
||||
}
|
||||
final proxies = (jsonDecode(response.data! as String)["proxies"]
|
||||
as Map<String, dynamic>)
|
||||
final proxies = ((jsonDecode(response.data! as String)
|
||||
as Map<String, dynamic>)["proxies"] as Map<String, dynamic>)
|
||||
.entries
|
||||
.map(
|
||||
(e) {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// ignore_for_file: avoid_manual_providers_as_generated_provider_dependency
|
||||
import 'package:hiddify/core/prefs/prefs.dart';
|
||||
import 'package:hiddify/domain/singbox/config_options.dart';
|
||||
import 'package:hiddify/utils/pref_notifier.dart';
|
||||
@@ -68,9 +69,8 @@ final setSystemProxyStore =
|
||||
|
||||
@riverpod
|
||||
ConfigOptions configOptions(ConfigOptionsRef ref) => ConfigOptions(
|
||||
executeConfigAsIs: ref.watch(debugModeNotifierProvider)
|
||||
? ref.watch(executeConfigAsIs)
|
||||
: false,
|
||||
executeConfigAsIs:
|
||||
ref.watch(debugModeNotifierProvider) && ref.watch(executeConfigAsIs),
|
||||
logLevel: ref.watch(logLevelStore),
|
||||
resolveDestination: ref.watch(resolveDestinationStore),
|
||||
ipv6Mode: ref.watch(ipv6ModeStore),
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import 'dart:convert';
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:dartx/dartx.dart';
|
||||
import 'package:freezed_annotation/freezed_annotation.dart';
|
||||
|
||||
@@ -25,9 +25,13 @@ class MultiLogPrinter extends LoggyPrinter {
|
||||
}
|
||||
|
||||
class FileLogPrinter extends LoggyPrinter {
|
||||
FileLogPrinter(String filePath) : _logFile = File(filePath);
|
||||
FileLogPrinter(
|
||||
String filePath, {
|
||||
this.minLevel = LogLevel.debug,
|
||||
}) : _logFile = File(filePath);
|
||||
|
||||
final File _logFile;
|
||||
final LogLevel minLevel;
|
||||
|
||||
late final _sink = _logFile.openWrite(
|
||||
mode: FileMode.writeOnly,
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import 'package:dartx/dartx.dart';
|
||||
import 'package:hiddify/utils/validators.dart';
|
||||
|
||||
typedef ProfileLink = ({String url, String name});
|
||||
|
||||
@@ -6,7 +6,7 @@ class SentryLoggyIntegration extends LoggyPrinter
|
||||
implements Integration<SentryOptions> {
|
||||
SentryLoggyIntegration({
|
||||
LogLevel minBreadcrumbLevel = LogLevel.info,
|
||||
LogLevel minEventLevel = LogLevel.error,
|
||||
LogLevel minEventLevel = LogLevel.warning,
|
||||
}) : _minBreadcrumbLevel = minBreadcrumbLevel,
|
||||
_minEventLevel = minEventLevel;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user