NSURLErrorBackgroundSessionWasDisconnected
The app is suspended or exits while a background data task is processing.
Declaration
var NSURLErrorBackgroundSessionWasDisconnected: Int { get }Discussion
If your app has created a background data task and the app is then suspended, the task will fail with this error code. To prevent this, when you receive the response, convert the data task to a download task.
See Also
URL Errors
NSURLErrorAppTransportSecurityRequiresSecureConnectionNSURLErrorBackgroundSessionInUseByAnotherProcessNSURLErrorBackgroundSessionRequiresSharedContainerNSURLErrorBadServerResponseNSURLErrorBadURLNSURLErrorCallIsActiveNSURLErrorCancelledNSURLErrorCannotCloseFileNSURLErrorCannotConnectToHostNSURLErrorCannotCreateFileNSURLErrorCannotDecodeContentDataNSURLErrorCannotDecodeRawDataNSURLErrorCannotFindHostNSURLErrorCannotLoadFromNetworkNSURLErrorCannotMoveFile