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

Unified Diff: chrome/service/cloud_print/cloud_print_proxy.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 years, 8 months 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 side-by-side diff with in-line comments
Download patch
Index: chrome/service/cloud_print/cloud_print_proxy.cc
diff --git a/chrome/service/cloud_print/cloud_print_proxy.cc b/chrome/service/cloud_print/cloud_print_proxy.cc
index a65da813798a22d865423a59e6b2be928515dd21..12eee709d301b44a596057be09efa79f571e0e98 100644
--- a/chrome/service/cloud_print/cloud_print_proxy.cc
+++ b/chrome/service/cloud_print/cloud_print_proxy.cc
@@ -85,10 +85,10 @@ void CloudPrintProxy::EnableForUser(const std::string& lsid) {
DCHECK(backend_.get());
// Read persisted robot credentials because we may decide to reuse it if the
// passed in LSID belongs the same user.
- std::string robot_refresh_token =
- service_prefs_->GetString(prefs::kCloudPrintRobotRefreshToken, "");
+ std::string robot_refresh_token = service_prefs_->GetString(
+ prefs::kCloudPrintRobotRefreshToken, std::string());
std::string robot_email =
- service_prefs_->GetString(prefs::kCloudPrintRobotEmail, "");
+ service_prefs_->GetString(prefs::kCloudPrintRobotEmail, std::string());
user_email_ = service_prefs_->GetString(prefs::kCloudPrintEmail, user_email_);
// If we have been passed in an LSID, we want to use this to authenticate.
@@ -104,7 +104,7 @@ void CloudPrintProxy::EnableForUser(const std::string& lsid) {
} else {
// Finally see if we have persisted user credentials (legacy case).
std::string cloud_print_token =
- service_prefs_->GetString(prefs::kCloudPrintAuthToken, "");
+ service_prefs_->GetString(prefs::kCloudPrintAuthToken, std::string());
DCHECK(!cloud_print_token.empty());
backend_->InitializeWithToken(cloud_print_token);
}
@@ -124,7 +124,7 @@ void CloudPrintProxy::EnableForUserWithRobot(
ShutdownBackend();
std::string proxy_id(
- service_prefs_->GetString(prefs::kCloudPrintProxyId, ""));
+ service_prefs_->GetString(prefs::kCloudPrintProxyId, std::string()));
service_prefs_->RemovePref(prefs::kCloudPrintRoot);
if (!proxy_id.empty()) {
// Keep only proxy id;
@@ -204,7 +204,8 @@ void CloudPrintProxy::GetProxyInfo(CloudPrintProxyInfo* info) {
// If the Cloud Print service is not enabled, we may need to read the old
// value of proxy_id from prefs.
if (info->proxy_id.empty())
- info->proxy_id = service_prefs_->GetString(prefs::kCloudPrintProxyId, "");
+ info->proxy_id =
+ service_prefs_->GetString(prefs::kCloudPrintProxyId, std::string());
}
void CloudPrintProxy::CheckCloudPrintProxyPolicy() {

Powered by Google App Engine
This is Rietveld 408576698