refactor: replace base::StringPrintf() calls with absl::StrFormat() (#44515)
refactor: replace base::StringPrintf() calls with absl::StFormat()
The former is now a pass-through for the latter and is slated for removal
Xref: https://issues.chromium.org/issues/40241565
4907781
This commit is contained in:
parent
c63d0d61e7
commit
726d439399
15 changed files with 59 additions and 61 deletions
|
@ -6,12 +6,12 @@
|
|||
|
||||
#include "base/i18n/rtl.h"
|
||||
#include "base/no_destructor.h"
|
||||
#include "base/strings/stringprintf.h"
|
||||
#include "chrome/browser/browser_process.h"
|
||||
#include "chrome/common/chrome_version.h"
|
||||
#include "content/public/common/user_agent.h"
|
||||
#include "electron/electron_version.h"
|
||||
#include "shell/browser/browser.h"
|
||||
#include "third_party/abseil-cpp/absl/strings/str_format.h"
|
||||
|
||||
namespace electron {
|
||||
|
||||
|
@ -42,7 +42,7 @@ std::string GetApplicationUserAgent() {
|
|||
user_agent = "Chrome/" CHROME_VERSION_STRING " " ELECTRON_PRODUCT_NAME
|
||||
"/" ELECTRON_VERSION_STRING;
|
||||
} else {
|
||||
user_agent = base::StringPrintf(
|
||||
user_agent = absl::StrFormat(
|
||||
"%s/%s Chrome/%s " ELECTRON_PRODUCT_NAME "/" ELECTRON_VERSION_STRING,
|
||||
name.c_str(), browser->GetVersion().c_str(), CHROME_VERSION_STRING);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue