mirror of
https://github.com/wwiinnddyy/LanMountainDesktop.git
synced 2026-06-23 09:54:25 +08:00
0.7.3
修东西
This commit is contained in:
@@ -337,6 +337,14 @@ public sealed class PostHogUsageTelemetryService : IDisposable
|
||||
["timestamp"] = timestamp.ToString("o"),
|
||||
["properties"] = new Dictionary<string, object?>
|
||||
{
|
||||
["install_id"] = installId,
|
||||
["app_version"] = TelemetryEnvironmentInfo.GetAppVersion(),
|
||||
["os_name"] = TelemetryEnvironmentInfo.GetOsName(),
|
||||
["os_version"] = TelemetryEnvironmentInfo.GetOsVersion(),
|
||||
["device_model"] = TelemetryEnvironmentInfo.GetDeviceModel(),
|
||||
["device_arch"] = TelemetryEnvironmentInfo.GetDeviceArchitecture(),
|
||||
["runtime_version"] = TelemetryEnvironmentInfo.GetRuntimeVersion(),
|
||||
["language"] = TelemetryEnvironmentInfo.GetSystemLanguage(),
|
||||
["launch_time_utc"] = timestamp.ToString("o")
|
||||
}
|
||||
};
|
||||
|
||||
@@ -78,25 +78,6 @@ public sealed class TelemetryIdentityService
|
||||
}
|
||||
}
|
||||
|
||||
public string RefreshTelemetryId()
|
||||
{
|
||||
lock (_syncRoot)
|
||||
{
|
||||
EnsureInitialized();
|
||||
|
||||
var snapshot = _settingsFacade.Settings.LoadSnapshot<AppSettingsSnapshot>(SettingsScope.App);
|
||||
snapshot.TelemetryId = GenerateId();
|
||||
_settingsFacade.Settings.SaveSnapshot(
|
||||
SettingsScope.App,
|
||||
snapshot,
|
||||
changedKeys: [nameof(AppSettingsSnapshot.TelemetryId)]);
|
||||
|
||||
_telemetryId = snapshot.TelemetryId ?? GenerateId();
|
||||
AppLogger.Info("TelemetryIdentity", $"Telemetry id refreshed. TelemetryId={_telemetryId}");
|
||||
return _telemetryId;
|
||||
}
|
||||
}
|
||||
|
||||
public bool MarkBaselineReported()
|
||||
{
|
||||
lock (_syncRoot)
|
||||
|
||||
Reference in New Issue
Block a user