From 1dfcb1d659ba8919c29fc3b7277f20450113a9e6 Mon Sep 17 00:00:00 2001 From: Konrad Dysput Date: Tue, 31 Oct 2023 18:59:25 +0100 Subject: [PATCH] Do not read application version as 'backtrace.version' --- .../Features/Attributes/DefaultAttributes.swift | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/Sources/Features/Attributes/DefaultAttributes.swift b/Sources/Features/Attributes/DefaultAttributes.swift index a5c2c1b6..eeaccd25 100644 --- a/Sources/Features/Attributes/DefaultAttributes.swift +++ b/Sources/Features/Attributes/DefaultAttributes.swift @@ -207,21 +207,8 @@ struct LibInfo: AttributesSource { private static let applicationGuidKey = "backtrace.unique.user.identifier" private static let applicationLangName = "backtrace-cocoa" - var backtraceVersion: String? { - -#if SWIFT_PACKAGE - if let build = Bundle.main.infoDictionary?["CFBundleShortVersionString"] { - return build as? String - } -#else - if let bundle = Bundle(identifier: "Backtrace.io.Backtrace"), - let build = bundle.infoDictionary?["CFBundleShortVersionString"] { - return build as? String - } -#endif - return nil - } - + var backtraceVersion = "2.0.1" + var immutable: [String: Any?] { return ["guid": LibInfo.guid(store: UserDefaultsStore.self).uuidString, "lang.name": LibInfo.applicationLangName,