Chromium Code Reviews| Index: ios/chrome/browser/experimental_flags.mm |
| diff --git a/ios/chrome/browser/experimental_flags.mm b/ios/chrome/browser/experimental_flags.mm |
| index 3e55afffe705303bde742af6e5a6d4b7625518ff..9aa1ea7bbf248a3db315d3b0e149a32693847de9 100644 |
| --- a/ios/chrome/browser/experimental_flags.mm |
| +++ b/ios/chrome/browser/experimental_flags.mm |
| @@ -19,6 +19,7 @@ |
| #include "base/strings/sys_string_conversions.h" |
| #include "components/autofill/core/common/autofill_switches.h" |
| #include "components/password_manager/core/common/password_manager_features.h" |
| +#include "components/payments/core/features.h" |
| #include "components/signin/core/common/signin_switches.h" |
| #include "components/variations/variations_associated_data.h" |
| #include "ios/chrome/browser/chrome_switches.h" |
| @@ -173,22 +174,7 @@ bool IsPasswordGenerationEnabled() { |
| } |
| bool IsPaymentRequestEnabled() { |
|
noyau (Ping after 24h)
2017/07/06 15:33:28
Can you get rid of this function and use IsEnabled
Mathieu
2017/07/06 15:34:30
Done!
|
| - // This call activates the field trial, if needed, so it must come before any |
| - // early returns. |
| - std::string group_name = |
| - base::FieldTrialList::FindFullName("IOSPaymentRequest"); |
| - |
| - // Check if the experimental flag is forced on or off. |
| - base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); |
| - if (command_line->HasSwitch(switches::kEnablePaymentRequest)) { |
| - return true; |
| - } else if (command_line->HasSwitch(switches::kDisablePaymentRequest)) { |
| - return false; |
| - } |
| - |
| - // Check if the Finch experiment is turned on. |
| - return base::StartsWith(group_name, "Enabled", |
| - base::CompareCase::INSENSITIVE_ASCII); |
| + return base::FeatureList::IsEnabled(payments::features::kWebPayments); |
| } |
| bool IsPhysicalWebEnabled() { |