File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ - (void)webView:(WKWebView *)webView startURLSchemeTask:(id <WKURLSchemeTask>)ur
4141 }
4242 loadFile = false ;
4343 startPath = [stringToLoad stringByReplacingOccurrencesOfString: @" /_http_proxy_" withString: @" http://" ];
44- // startPath = [stringToLoad stringByReplacingOccurrencesOfString:@"/_https_proxy_" withString:@"https://"];
44+ startPath = [startPath stringByReplacingOccurrencesOfString: @" /_https_proxy_" withString: @" https://" ];
4545 NSURL * requestUrl = [NSURL URLWithString: startPath];
4646 WKWebsiteDataStore * dataStore = [WKWebsiteDataStore defaultDataStore ];
4747 WKHTTPCookieStore * cookieStore = dataStore.httpCookieStore ;
@@ -63,14 +63,13 @@ - (void)webView:(WKWebView *)webView startURLSchemeTask:(id <WKURLSchemeTask>)ur
6363 NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *)response;
6464 NSArray * cookies = [NSHTTPCookie cookiesWithResponseHeaderFields: [httpResponse allHeaderFields ] forURL: response.URL];
6565 [[NSHTTPCookieStorage sharedHTTPCookieStorage ] setCookies: cookies forURL: httpResponse.URL mainDocumentURL: nil ];
66- cookies = [[NSHTTPCookieStorage sharedHTTPCookieStorage ] cookies ];
66+ cookies = [[NSHTTPCookieStorage sharedHTTPCookieStorage ] cookies ];
6767
6868 for (NSHTTPCookie * c in cookies)
6969 {
7070 dispatch_async (dispatch_get_global_queue ( DISPATCH_QUEUE_PRIORITY_DEFAULT, 0 ), ^(void ){
7171 // running in background thread is necessary because setCookie otherwise fails
7272 dispatch_async (dispatch_get_main_queue (), ^(void ){
73- NSLog (@" sync cookie: %@ " , c.name );
7473 [cookieStore setCookie: c completionHandler: nil ];
7574 });
7675 });
You can’t perform that action at this time.
0 commit comments