@onekeyfe/react-native-sni-connect 3.0.81-alpha.1 → 3.0.81-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -90,7 +90,7 @@ final class SniConnectPinnedResolverLease {
90
90
  }
91
91
  }
92
92
 
93
- final class SniConnectSessionInvalidationDelegate: NSObject, URLSessionDelegate {
93
+ final class SniConnectSessionInvalidationDelegate: NSObject, URLSessionTaskDelegate {
94
94
  private let hostname: String
95
95
  private let ip: String
96
96
  private let resolverLease: SniConnectPinnedResolverLease
@@ -110,6 +110,16 @@ final class SniConnectSessionInvalidationDelegate: NSObject, URLSessionDelegate
110
110
  ("success", error == nil),
111
111
  ]))
112
112
  }
113
+
114
+ func urlSession(
115
+ _ session: URLSession,
116
+ task: URLSessionTask,
117
+ willPerformHTTPRedirection response: HTTPURLResponse,
118
+ newRequest request: URLRequest,
119
+ completionHandler: @escaping (URLRequest?) -> Void
120
+ ) {
121
+ completionHandler(nil)
122
+ }
113
123
  }
114
124
 
115
125
  /// Core HTTPS client that enforces IP direct connection with SNI.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onekeyfe/react-native-sni-connect",
3
- "version": "3.0.81-alpha.1",
3
+ "version": "3.0.81-alpha.3",
4
4
  "description": "A React Native library for SNI-based HTTP requests with DNS caching and request management",
5
5
  "main": "./lib/module/index.js",
6
6
  "types": "./lib/typescript/src/index.d.ts",