I am getting an error when I am enabling the extension I have added in my project please tell me how to solve this here is the screenshot Error Image
If you need any other details please ask me I will provide them.
private func addAllBlockingPhoneNumbers(to context: CXCallDirectoryExtensionContext) {
for i in 0...numbers.count - 1
{
let allPhoneNumbers: [CXCallDirectoryPhoneNumber] = [ numbers[i] ]
for phoneNumber in allPhoneNumbers {
context.addBlockingEntry(withNextSequentialPhoneNumber: phoneNumber)
}
}
}
----------------------------
override func beginRequest(with context: CXCallDirectoryExtensionContext) {
context.delegate = self
numbers = DBManager.shared.selectContacts()
}