Skip to content

Commit

Permalink
Add Call Direction in sendPhoneCallEvents description to fix customPa…
Browse files Browse the repository at this point in the history
…rams being null in Active Call on Answer.
  • Loading branch information
agent515 committed May 8, 2024
1 parent 211b082 commit 599a9e7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1735,7 +1735,7 @@ class TwilioVoicePlugin : FlutterPlugin, MethodCallHandler, EventChannel.StreamH
}
}.toString()
// callSid = callHandle
logEvents("", arrayOf("Answer", from, to, params))
logEvents("", arrayOf("Answer", from, to, CallDirection.INCOMING.label, params))
}

TVNativeCallActions.ACTION_DTMF -> {
Expand Down
2 changes: 1 addition & 1 deletion ios/Classes/SwiftTwilioVoicePlugin.swift
Original file line number Diff line number Diff line change
Expand Up @@ -928,7 +928,7 @@ public class SwiftTwilioVoicePlugin: NSObject, FlutterPlugin, FlutterStreamHand
}
self.sendPhoneCallEvents(description: "LOG|performAnswerVoiceCall: answering call", isError: false)
let theCall = ci.accept(options: acceptOptions, delegate: self)
self.sendPhoneCallEvents(description: "Answer|\(theCall.from!)|\(theCall.to!)\(formatCustomParams(params: ci.customParameters))", isError:false)
self.sendPhoneCallEvents(description: "Answer|\(theCall.from!)|\(theCall.to!)|Incoming\(formatCustomParams(params: ci.customParameters))", isError:false)
self.call = theCall
self.callKitCompletionCallback = completionHandler
self.callInvite = nil
Expand Down

0 comments on commit 599a9e7

Please sign in to comment.