Fix starting direct calls

This commit is contained in:
ayumi-signal 2024-09-19 10:58:47 -07:00 committed by GitHub
parent d488239240
commit 90970921b5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -495,10 +495,12 @@ export function getCallDetailsFromDirectCall(
peerId: AciString | string,
call: Call
): CallDetails {
const ringerId = call.isIncoming ? call.remoteUserId : null;
return callDetailsSchema.parse({
callId: Long.fromValue(call.callId).toString(),
peerId,
ringerId: call.isIncoming ? call.remoteUserId : null,
ringerId,
startedById: ringerId,
mode: CallMode.Direct,
type: call.isVideoCall ? CallType.Video : CallType.Audio,
direction: call.isIncoming