Skip to content

Commit ef4bbe6

Browse files
committed
fix unit tests
1 parent 677a219 commit ef4bbe6

File tree

1 file changed

+9
-8
lines changed
  • core/src/main/java/com/segment/analytics/kotlin/core/platform

1 file changed

+9
-8
lines changed

core/src/main/java/com/segment/analytics/kotlin/core/platform/Timeline.kt

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -82,14 +82,6 @@ internal class Timeline {
8282
it["message"] = "Exception executing plugin"
8383
}
8484
}
85-
Telemetry.increment(Telemetry.INTEGRATION_METRIC) {
86-
it["message"] = "added"
87-
if (plugin is DestinationPlugin && plugin.key != "") {
88-
it["plugin"] = "${plugin.type}-${plugin.key}"
89-
} else {
90-
it["plugin"] = "${plugin.type}-${plugin.javaClass}"
91-
}
92-
}
9385
plugins[plugin.type]?.add(plugin)
9486
with(analytics) {
9587
analyticsScope.launch(analyticsDispatcher) {
@@ -108,6 +100,15 @@ internal class Timeline {
108100
}
109101
}
110102
}
103+
104+
Telemetry.increment(Telemetry.INTEGRATION_METRIC) {
105+
it["message"] = "added"
106+
if (plugin is DestinationPlugin && plugin.key != "") {
107+
it["plugin"] = "${plugin.type}-${plugin.key}"
108+
} else {
109+
it["plugin"] = "${plugin.type}-${plugin.javaClass}"
110+
}
111+
}
111112
}
112113

113114
// Remove a registered plugin

0 commit comments

Comments
 (0)