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

Unified Diff: components/ntp_snippets/content_suggestion.h

Issue 2829963005: [Remote suggestions] Get favicon URLs from archive (Closed)
Patch Set: Comments #3 Created 3 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
« no previous file with comments | « no previous file | components/ntp_snippets/content_suggestion.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/ntp_snippets/content_suggestion.h
diff --git a/components/ntp_snippets/content_suggestion.h b/components/ntp_snippets/content_suggestion.h
index dca3c24367a3b8e319aa307a9d3d555685a75b27..5bc647e4cdab112150b0dfa84a3f12d5b5858a52 100644
--- a/components/ntp_snippets/content_suggestion.h
+++ b/components/ntp_snippets/content_suggestion.h
@@ -116,13 +116,15 @@ class ContentSuggestion {
// Path is trimmed for the URL because the current favicon server backend
// prefers it this way.
GURL url_with_favicon() const {
- return url_with_favicon_.is_valid() ? url_with_favicon_.GetWithEmptyPath()
- : url_.GetWithEmptyPath();
+ return url_with_favicon_.is_valid() ? GetFaviconDomain(url_with_favicon_)
+ : GetFaviconDomain(url_);
}
void set_url_with_favicon(const GURL& url_with_favicon) {
url_with_favicon_ = url_with_favicon;
}
+ static GURL GetFaviconDomain(const GURL& favicon_url);
+
// Title of the suggestion.
const base::string16& title() const { return title_; }
void set_title(const base::string16& title) { title_ = title; }
« no previous file with comments | « no previous file | components/ntp_snippets/content_suggestion.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698