From 4fd4e9566b6411ac00a4036710153b9b36fc8e07 Mon Sep 17 00:00:00 2001 From: RyosukeCla Date: Wed, 26 Jun 2024 16:02:11 +0900 Subject: [PATCH 1/2] [ios] use N_ERROR_RECORD instead of hard coded string --- ios/Nativebrik/Nativebrik/data/track.swift | 4 ++-- ios/Nativebrik/Nativebrik/generated.swift | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ios/Nativebrik/Nativebrik/data/track.swift b/ios/Nativebrik/Nativebrik/data/track.swift index c37f5f4..16e82fe 100644 --- a/ios/Nativebrik/Nativebrik/data/track.swift +++ b/ios/Nativebrik/Nativebrik/data/track.swift @@ -160,13 +160,13 @@ class TrackRespositoryImpl: TrackRepository2 { }) ?? false) || (crashRecord.reason?.contains("Nativebrik") ?? false) self.buffer.append(TrackEvent( typename: .Event, - name: "N_CRASH_RECORD", + name: TriggerEventNameDefs.N_ERROR_RECORD.rawValue, timestamp: formatToISO8601(getCurrentDate()) )) if causedByNativebrik { self.buffer.append(TrackEvent( typename: .Event, - name: "N_CRASH_IN_SDK_RECORD", + name: TriggerEventNameDefs.N_ERROR_IN_SDK_RECORD.rawValue, timestamp: formatToISO8601(getCurrentDate()) )) } diff --git a/ios/Nativebrik/Nativebrik/generated.swift b/ios/Nativebrik/Nativebrik/generated.swift index bf68486..4c727d9 100644 --- a/ios/Nativebrik/Nativebrik/generated.swift +++ b/ios/Nativebrik/Nativebrik/generated.swift @@ -290,6 +290,8 @@ enum TriggerEventNameDefs: String, Decodable, Encodable { case USER_ENTER_TO_APP = "USER_ENTER_TO_APP" case USER_ENTER_TO_APP_FIRSTLY = "USER_ENTER_TO_APP_FIRSTLY" case USER_ENTER_TO_FOREGROUND = "USER_ENTER_TO_FOREGROUND" + case N_ERROR_RECORD = "N_ERROR_RECORD" + case N_ERROR_IN_SDK_RECORD = "N_ERROR_IN_SDK_RECORD" case unknown = "unknown" init(from decoder: Decoder) throws { self = try TriggerEventNameDefs(rawValue: decoder.singleValueContainer().decode(RawValue.self)) ?? .unknown From eda4f216d319b486e9417b6543fda1e1a28d0ae6 Mon Sep 17 00:00:00 2001 From: RyosukeCla Date: Wed, 26 Jun 2024 16:03:25 +0900 Subject: [PATCH 2/2] [ios] v0.5.9 --- Nativebrik.podspec | 2 +- ios/Nativebrik/Nativebrik/sdk.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Nativebrik.podspec b/Nativebrik.podspec index 6e98798..77bbe33 100644 --- a/Nativebrik.podspec +++ b/Nativebrik.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'Nativebrik' - s.version = '0.5.8' + s.version = '0.5.9' s.summary = 'Nativebrik SDK' s.description = <<-DESC Nativebrik SDK for iOS. diff --git a/ios/Nativebrik/Nativebrik/sdk.swift b/ios/Nativebrik/Nativebrik/sdk.swift index 25b476e..74b001d 100644 --- a/ios/Nativebrik/Nativebrik/sdk.swift +++ b/ios/Nativebrik/Nativebrik/sdk.swift @@ -9,7 +9,7 @@ import Foundation import SwiftUI import Combine -public let nativebrikSdkVersion = "0.5.8" +public let nativebrikSdkVersion = "0.5.9" public let isNativebrikAvailable: Bool = { if #available(iOS 15.0, *) { return true