Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(685)

Side by Side Diff: components/cryptauth/cryptauth_api_call_flow.cc

Issue 2502343003: Moved //components/proximity_auth/cryptauth to //components/cryptauth. (Closed)
Patch Set: Fixed proto #includes. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/proximity_auth/cryptauth/cryptauth_api_call_flow.h" 5 #include "components/cryptauth/cryptauth_api_call_flow.h"
6 6
7 #include "base/strings/string_number_conversions.h" 7 #include "base/strings/string_number_conversions.h"
8 #include "components/proximity_auth/logging/logging.h" 8 #include "components/proximity_auth/logging/logging.h"
9 #include "net/url_request/url_fetcher.h" 9 #include "net/url_request/url_fetcher.h"
10 10
11 namespace proximity_auth { 11 namespace cryptauth {
12 12
13 namespace { 13 namespace {
14 14
15 const char kResponseBodyError[] = "Failed to get response body"; 15 const char kResponseBodyError[] = "Failed to get response body";
16 const char kRequestFailedError[] = "Request failed"; 16 const char kRequestFailedError[] = "Request failed";
17 const char kHttpStatusErrorPrefix[] = "HTTP status: "; 17 const char kHttpStatusErrorPrefix[] = "HTTP status: ";
18 18
19 } // namespace 19 } // namespace
20 20
21 CryptAuthApiCallFlow::CryptAuthApiCallFlow() { 21 CryptAuthApiCallFlow::CryptAuthApiCallFlow() {
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 error_message = kRequestFailedError; 74 error_message = kRequestFailedError;
75 } 75 }
76 76
77 std::string response; 77 std::string response;
78 source->GetResponseAsString(&response); 78 source->GetResponseAsString(&response);
79 PA_LOG(INFO) << "API call failed:\n" << response; 79 PA_LOG(INFO) << "API call failed:\n" << response;
80 error_callback_.Run(error_message); 80 error_callback_.Run(error_message);
81 } 81 }
82 82
83 } // proximity_auth 83 } // proximity_auth
OLDNEW
« no previous file with comments | « components/cryptauth/cryptauth_api_call_flow.h ('k') | components/cryptauth/cryptauth_api_call_flow_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698