Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ let package = Package(
dependencies: [
// Dependencies declare other packages that this package depends on.
// .package(url: /* package url */, from: "1.0.0"),
.package(url: "https://github.com/segmentio/analytics-swift.git", from: "1.6.0")
.package(url: "https://github.com/segmentio/analytics-swift.git", from: "1.9.1")
],
targets: [
// Targets are the basic building blocks of a package. A target can define a module or a test suite.
Expand Down
6 changes: 3 additions & 3 deletions Sources/SegmentAmplitude/AmplitudeSession.swift
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public class AmplitudeSession: EventPlugin, iOSLifecycle {
if adjustedProps == nil {
adjustedProps = try? JSON(["name": screenName])
} else {
adjustedProps?.setValue(screenName, forKeyPath: KeyPath("name"))
adjustedProps?.setValue(screenName, forKeyPath: JSONKeyPath("name"))
}
screenEvent.properties = adjustedProps
workingEvent = screenEvent as? T
Expand All @@ -132,7 +132,7 @@ public class AmplitudeSession: EventPlugin, iOSLifecycle {
// if it's amp specific stuff, disable all the integrations except for amp.
if eventName.contains(Constants.ampPrefix) || eventName == Constants.ampSessionStartEvent || eventName == Constants.ampSessionEndEvent {
var integrations = disableAllIntegrations(integrations: trackEvent.integrations)
integrations?.setValue(["session_id": eventSessionID], forKeyPath: KeyPath(key))
integrations?.setValue(["session_id": eventSessionID], forKeyPath: JSONKeyPath(key))
trackEvent.integrations = integrations
}

Expand Down Expand Up @@ -186,7 +186,7 @@ extension AmplitudeSession {
var result = integrations
if let keys = integrations?.dictionaryValue?.keys {
for key in keys {
result?.setValue(false, forKeyPath: KeyPath(key))
result?.setValue(false, forKeyPath: JSONKeyPath(key))
}
}
return result
Expand Down