с использованием xcode 10.1 и swift версии 4.2 я делаю сборку, но я получил эту ошибку быстрого компилятора (команда завершилась неудачно из-за сигнала: ошибка сегментации: 11) и "Во время передачи SIL для 'successFbLoginResponse (response :)' в ... . "вот код с ошибкой:
func successFbLoginResponse(response: DataResponse<Any>) {
print(response)
if let result = response.result.value {
let JSON = result as! NSDictionary
let ok = JSON[kok] as! NSNumber
if ok == 1 {
self.currentUploadingCount += 1
self.multipleFileProgressView.progress = Float(self.currentUploadingCount)/Float(self.totalItems)
self.multipleFileProgressLabel.text = "\(self.currentUploadingCount) \(kof) \(self.totalItems) \(kfiles_have_been_uploaded)"
let progressDictionary: [String: Int] = [kuploadedCount: self.currentUploadingCount, ktotalCount: self.totalItems]
// post a notification
NotificationCenter.default.post(name: NSNotification.Name(kUploadProgress), object: nil, userInfo: progressDictionary)
if self.currentUploadingCount < self.totalItems {
self.uploadItem(item: (self.assets?[self.currentUploadingCount])!)
} else {
self.assets?.removeAll()
self.singleFileProgressView.progress = 0
self.singleFileProgressLabel.text = kZeroPercent
self.multipleFileProgressView.progress = 0
self.uploadComplete = true
delegate?.recallApi()
NotificationCenter.default.post(name: NSNotification.Name(kcompletion), object: nil, userInfo: nil)
Utility.showAlertWithSingleOption(controller: self, title: "", message: kUpload_is_done, preferredStyle: .alert, buttonText: kReturn, buttonHandler: { (action: UIAlertAction!) in
// _ = self.navigationController?.popViewController(animated: true)
if self.isPublicFile {
self.tabBarController?.selectedIndex = 0
} else {
self.tabBarController?.selectedIndex = 1
}
})
}
} else {
self.uploadItem(item: (self.assets?[self.currentUploadingCount])!)
}
} else {
self.singleFileProgressView.progress = 0
networkFailureAction()
}
}