| Index: components/history/core/browser/top_sites_database.cc
|
| diff --git a/components/history/core/browser/top_sites_database.cc b/components/history/core/browser/top_sites_database.cc
|
| index 7e9fc819a0a5f4c92013add5553ac60c6bd45215..3ae0a1088dc4b79f6fb81b5a3dd7a5b12209135b 100644
|
| --- a/components/history/core/browser/top_sites_database.cc
|
| +++ b/components/history/core/browser/top_sites_database.cc
|
| @@ -12,6 +12,7 @@
|
| #include "base/files/file_util.h"
|
| #include "base/memory/ref_counted.h"
|
| #include "base/metrics/histogram_macros.h"
|
| +#include "base/strings/string_piece.h"
|
| #include "base/strings/string_split.h"
|
| #include "base/strings/string_util.h"
|
| #include "components/history/core/browser/history_types.h"
|
| @@ -87,9 +88,9 @@ bool InitTables(sql::Connection* db) {
|
|
|
| // Encodes redirects into a string.
|
| std::string GetRedirects(const MostVisitedURL& url) {
|
| - std::vector<std::string> redirects;
|
| - for (size_t i = 0; i < url.redirects.size(); i++)
|
| - redirects.push_back(url.redirects[i].spec());
|
| + std::vector<base::StringPiece> redirects;
|
| + for (const auto& redirect : url.redirects)
|
| + redirects.push_back(redirect.spec());
|
| return base::JoinString(redirects, " ");
|
| }
|
|
|
|
|