Index: components/ntp_snippets/content_suggestions_metrics.cc |
diff --git a/components/ntp_snippets/content_suggestions_metrics.cc b/components/ntp_snippets/content_suggestions_metrics.cc |
index 5d4fbe169ad5a462da482bcc432b02bbbaa3b785..dfe86a9e658720dbc4998e082945e81378aefcc6 100644 |
--- a/components/ntp_snippets/content_suggestions_metrics.cc |
+++ b/components/ntp_snippets/content_suggestions_metrics.cc |
@@ -43,6 +43,8 @@ const char kHistogramMoreButtonClicked[] = |
const char kPerCategoryHistogramFormat[] = "%s.%s"; |
+// Each suffix here should correspond to an entry under histogram suffix |
+// ContentSuggestionCategory in histograms.xml. |
std::string GetCategorySuffix(Category category) { |
// TODO(treib): Find a way to produce a compile error if a known category |
// isn't listed here. |
@@ -52,6 +54,8 @@ std::string GetCategorySuffix(Category category) { |
return "Downloads"; |
if (category.IsKnownCategory(KnownCategories::BOOKMARKS)) |
return "Bookmarks"; |
+ if (category.IsKnownCategory(KnownCategories::FOREIGN_TABS)) |
+ return "ForeignTabs"; |
if (category.IsKnownCategory(KnownCategories::ARTICLES)) |
return "Articles"; |
// All other categories go into a single "Experimental" bucket. |