From 71c3b61bdd17b0ca70c99efcab204a82b82f3b59 Mon Sep 17 00:00:00 2001 From: xkeyC <3334969096@qq.com> Date: Thu, 13 Nov 2025 20:24:09 +0800 Subject: [PATCH] feat: AnalyticsApi disable firstLaunch --- lib/app.dart | 8 ++++---- lib/common/io/rs_http.dart | 5 +---- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/lib/app.dart b/lib/app.dart index b945658..2b13883 100644 --- a/lib/app.dart +++ b/lib/app.dart @@ -121,10 +121,10 @@ class AppGlobalModel extends _$AppGlobalModel { if (!kIsWeb) Hive.init("$applicationSupportDir/db"); final box = await Hive.openBox("app_conf"); state = state.copyWith(appConfBox: box); - if (box.get("install_id", defaultValue: "") == "") { - await box.put("install_id", const Uuid().v4()); - AnalyticsApi.touch("firstLaunch"); - } + // if (box.get("install_id", defaultValue: "") == "") { + // await box.put("install_id", const Uuid().v4()); + // AnalyticsApi.touch("firstLaunch"); + // } final deviceUUID = box.get("install_id", defaultValue: ""); final localeCode = box.get("app_locale", defaultValue: null); Locale? locale; diff --git a/lib/common/io/rs_http.dart b/lib/common/io/rs_http.dart index 8f2870d..45d28c5 100644 --- a/lib/common/io/rs_http.dart +++ b/lib/common/io/rs_http.dart @@ -10,10 +10,7 @@ class RSHttp { static Map _defaultHeaders = {}; static Future init() async { - _defaultHeaders = { - "User-Agent": - "SCToolBox/${ConstConf.appVersion} (${ConstConf.appVersionCode})${ConstConf.isMSE ? "" : " DEV"} RSHttp", - }; + _defaultHeaders = {}; _dio = Dio( BaseOptions(