李昊 4 年之前
父節點
當前提交
4f6c8ffe8c
共有 1 個文件被更改,包括 3 次插入3 次删除
  1. 3 3
      GxPress/Repository/GxPress.Repository.Implement/UserRepository.cs

+ 3 - 3
GxPress/Repository/GxPress.Repository.Implement/UserRepository.cs

@@ -655,9 +655,9 @@ namespace GxPress.Repository.Implement
                 // {
                 //     ServerCertificateCustomValidationCallback = (message, certificate2, arg3, arg4) => true
                 // };
-                HttpClientHandler clientHandler = new HttpClientHandler();
-                clientHandler.ServerCertificateCustomValidationCallback = (sender, cert, chain, sslPolicyErrors) => { return true; };
-                HttpClient httpClient = new HttpClient(clientHandler); //http对象
+                // HttpClientHandler clientHandler = new HttpClientHandler();
+                // clientHandler.ServerCertificateCustomValidationCallback = (sender, cert, chain, sslPolicyErrors) => { return true; };
+                HttpClient httpClient = new HttpClient(); //http对象
                 HttpResponseMessage response = await httpClient.PostAsync(
                     $"{imServiceUrl}/users",
                     new JsonContent(new { username = request.Phone, password = "123456", nickname = request.Name }));