mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-10-31 16:24:11 +00:00
Automatically silence ringing calls after 15 seconds of inactivity
This commit is contained in:
committed by
Stefan Ceriu
parent
f6c476eeca
commit
e76fabf18c
@@ -124,6 +124,13 @@ class ElementCallService: NSObject, ElementCallServiceProtocol, PKPushRegistryDe
|
||||
|
||||
completion()
|
||||
}
|
||||
|
||||
Task { [weak self, callProvider, callID] in
|
||||
try? await Task.sleep(for: .seconds(15))
|
||||
if let ongoingCallID = self?.ongoingCallID, ongoingCallID == callID {
|
||||
callProvider.reportCall(with: callID, endedAt: .now, reason: .unanswered)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// MARK: - CXProviderDelegate
|
||||
|
||||
Reference in New Issue
Block a user