From 18effc433e66053931cb22d2c519d96ceefc8de6 Mon Sep 17 00:00:00 2001 From: Navan Chauhan Date: Tue, 19 Dec 2023 12:51:31 -0700 Subject: add support for VisionOS --- Sources/swiftGopherClient/gopherClient.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/swiftGopherClient/gopherClient.swift b/Sources/swiftGopherClient/gopherClient.swift index c7542ee..e44bfcf 100644 --- a/Sources/swiftGopherClient/gopherClient.swift +++ b/Sources/swiftGopherClient/gopherClient.swift @@ -20,7 +20,7 @@ public class GopherClient { /// /// It automatically chooses the appropriate `EventLoopGroup` based on the running platform. public init() { - if #available(macOS 10.14, iOS 12.0, tvOS 12.0, watchOS 6.0, *) { + if #available(macOS 10.14, iOS 12.0, tvOS 12.0, watchOS 6.0, visionOS 1.0, *) { self.group = NIOTSEventLoopGroup() } else { self.group = MultiThreadedEventLoopGroup(numberOfThreads: System.coreCount) @@ -44,7 +44,7 @@ public class GopherClient { to host: String, port: Int = 70, message: String, completion: @escaping (Result<[gopherItem], Error>) -> Void ) { - if #available(macOS 10.14, iOS 12.0, tvOS 12.0, watchOS 6.0, *) { + if #available(macOS 10.14, iOS 12.0, tvOS 12.0, watchOS 6.0, visionOS 1.0, *) { let bootstrap = NIOTSConnectionBootstrap(group: group) .channelOption(ChannelOptions.socketOption(.so_reuseaddr), value: 1) .channelInitializer { channel in -- cgit v1.2.3