From fa1bbaf960a53c7ae21632322274c3caa62dae58 Mon Sep 17 00:00:00 2001 From: Jared McFarland Date: Mon, 17 Apr 2023 15:33:53 -0700 Subject: [PATCH] safer handling of nil superProperties --- ios/AutomaticProperties.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ios/AutomaticProperties.swift b/ios/AutomaticProperties.swift index c49ce60e..e6889f74 100644 --- a/ios/AutomaticProperties.swift +++ b/ios/AutomaticProperties.swift @@ -5,7 +5,7 @@ class AutomaticProperties { static var peopleProperties: Dictionary = [:]; static func setAutomaticProperties(_ properties: [String: Any]) { - for (key,value) in properties { + for (key,value) in properties ?? [:] { peopleProperties[key] = MixpanelTypeHandler.mixpanelTypeValue(value) } }