diff options
Diffstat (limited to 'chrome/browser/sync/profile_sync_components_factory_impl.cc')
-rw-r--r-- | chrome/browser/sync/profile_sync_components_factory_impl.cc | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/chrome/browser/sync/profile_sync_components_factory_impl.cc b/chrome/browser/sync/profile_sync_components_factory_impl.cc index 5b564fd..207a0a7 100644 --- a/chrome/browser/sync/profile_sync_components_factory_impl.cc +++ b/chrome/browser/sync/profile_sync_components_factory_impl.cc @@ -115,7 +115,11 @@ syncer::ModelTypeSet GetDisabledTypesFromCommandLine( syncer::ModelTypeSet GetEnabledTypesFromCommandLine( const base::CommandLine& command_line) { - return syncer::ModelTypeSet(); + syncer::ModelTypeSet enabled_types; + if (command_line.HasSwitch(autofill::switches::kEnableWalletMetadataSync)) + enabled_types.Put(syncer::AUTOFILL_WALLET_METADATA); + + return enabled_types; } } // namespace @@ -189,10 +193,10 @@ void ProfileSyncComponentsFactoryImpl::RegisterCommonDataTypes( syncer::AUTOFILL_WALLET_DATA)); } - // Wallet metadata sync depends on Wallet data sync. Register if Wallet data - // is syncing and metadata sync is not explicitly disabled. - if (!wallet_disabled && - !disabled_types.Has(syncer::AUTOFILL_WALLET_METADATA)) { + // Wallet metadata sync depends on Wallet data sync and is disabled by + // default. Register if Wallet data is syncing and metadata sync is explicitly + // enabled. + if (!wallet_disabled && enabled_types.Has(syncer::AUTOFILL_WALLET_METADATA)) { sync_service->RegisterDataTypeController( new browser_sync::AutofillWalletDataTypeController( BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI), |