Replace local code with updated Roxas and SideKit

Signed-off-by: Joseph Mattello <mail@joemattiello.com>
This commit is contained in:
Joseph Mattello
2023-02-25 01:37:52 -05:00
committed by Joe Mattiello
parent 4e84dc4cc8
commit f270ecc537
14 changed files with 124 additions and 1200 deletions

View File

@@ -8,6 +8,7 @@
import Foundation
import Network
import SideKit
public class NetworkConnection: NSObject, Connection
{
@@ -29,7 +30,7 @@ public class NetworkConnection: NSObject, Connection
{
self.nwConnection.receive(minimumIncompleteLength: expectedSize, maximumLength: expectedSize) { (data, context, isComplete, error) in
guard data != nil || error != nil else {
return completionHandler(nil, ALTServerError(.lostConnection))
return completionHandler(nil, ALTServerError.lostConnection(underlyingError: error))
}
completionHandler(data, error)