| Index: components/payments/core/journey_logger.cc
|
| diff --git a/components/payments/core/journey_logger.cc b/components/payments/core/journey_logger.cc
|
| index c7d08f2cf5d36bf09fa360e853b327ff09bf32e4..a62e2e23fcb22b4e8b01eb175516670b203857d8 100644
|
| --- a/components/payments/core/journey_logger.cc
|
| +++ b/components/payments/core/journey_logger.cc
|
| @@ -54,10 +54,11 @@ std::string GetHistogramNameSuffix(
|
|
|
| } // namespace
|
|
|
| -JourneyLogger::JourneyLogger()
|
| +JourneyLogger::JourneyLogger(bool is_incognito)
|
| : was_can_make_payments_used_(false),
|
| could_make_payment_(false),
|
| - was_show_called_(false) {}
|
| + was_show_called_(false),
|
| + is_incognito_(is_incognito) {}
|
|
|
| JourneyLogger::~JourneyLogger() {}
|
|
|
| @@ -150,6 +151,11 @@ void JourneyLogger::RecordSectionSpecificStats(
|
|
|
| void JourneyLogger::RecordCanMakePaymentStats(
|
| CompletionStatus completion_status) {
|
| + // CanMakePayment always returns true in incognito mode. Don't log the
|
| + // metrics.
|
| + if (is_incognito_)
|
| + return;
|
| +
|
| // Record CanMakePayment usage.
|
| UMA_HISTOGRAM_ENUMERATION("PaymentRequest.CanMakePayment.Usage",
|
| was_can_make_payments_used_
|
|
|