Index: chrome/browser/sync/profile_sync_components_factory_impl.cc |
diff --git a/chrome/browser/sync/profile_sync_components_factory_impl.cc b/chrome/browser/sync/profile_sync_components_factory_impl.cc |
index 211f7f69cd1f48d69df1fe54fad00883eaa3e2ef..a0eecba26144eabf6020819a4af5d6ae1bfe4206 100644 |
--- a/chrome/browser/sync/profile_sync_components_factory_impl.cc |
+++ b/chrome/browser/sync/profile_sync_components_factory_impl.cc |
@@ -117,7 +117,11 @@ |
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 |
@@ -191,10 +195,10 @@ |
error_callback, sync_client, 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), |