mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 19:11:45 +00:00
Add polls analytics (#1691)
* Refactor location events * Add poll analytics
This commit is contained in:
@@ -566,7 +566,7 @@ class RoomFlowCoordinator: FlowCoordinatorProtocol {
|
||||
self.analytics.trackComposer(inThread: false,
|
||||
isEditing: false,
|
||||
isReply: false,
|
||||
locationType: isUserLocation ? .myLocation : .pin,
|
||||
messageType: isUserLocation ? .location(.user) : .location(.pin),
|
||||
startsThread: nil)
|
||||
case .close:
|
||||
self.navigationSplitCoordinator.setSheetCoordinator(nil)
|
||||
@@ -606,6 +606,14 @@ class RoomFlowCoordinator: FlowCoordinatorProtocol {
|
||||
|
||||
let result = await roomProxy.createPoll(question: question, answers: options, pollKind: pollKind)
|
||||
|
||||
self.analytics.trackComposer(inThread: false,
|
||||
isEditing: false,
|
||||
isReply: false,
|
||||
messageType: .poll,
|
||||
startsThread: nil)
|
||||
|
||||
self.analytics.trackPollCreated(isUndisclosed: pollKind == .undisclosed, numberOfAnswers: options.count)
|
||||
|
||||
switch result {
|
||||
case .success:
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user