| Index: ios/chrome/browser/ui/settings/autofill_collection_view_controller.mm
|
| diff --git a/ios/chrome/browser/ui/settings/autofill_collection_view_controller.mm b/ios/chrome/browser/ui/settings/autofill_collection_view_controller.mm
|
| index 9f901101cf70c322bfbe2cf1271973fdddb3374f..a6a164aaec78942bfe129df3333d5e314a691216 100644
|
| --- a/ios/chrome/browser/ui/settings/autofill_collection_view_controller.mm
|
| +++ b/ios/chrome/browser/ui/settings/autofill_collection_view_controller.mm
|
| @@ -303,11 +303,6 @@ typedef NS_ENUM(NSInteger, ItemType) {
|
| _userInteractionInProgress = YES;
|
| [self setWalletEnabled:[switchView isOn]];
|
| _userInteractionInProgress = NO;
|
| - if ([switchView isOn]) {
|
| - [self insertCardSection];
|
| - } else {
|
| - [self removeCardSection];
|
| - }
|
| }
|
|
|
| #pragma mark - Switch Helpers
|
| @@ -389,27 +384,6 @@ typedef NS_ENUM(NSInteger, ItemType) {
|
| return sections;
|
| }
|
|
|
| -- (void)insertCardSection {
|
| - [self populateCardSection];
|
| - if ([self.collectionViewModel
|
| - hasSectionForSectionIdentifier:SectionIdentifierCards]) {
|
| - NSInteger section = [self.collectionViewModel
|
| - sectionForSectionIdentifier:SectionIdentifierCards];
|
| - [self.collectionView insertSections:[NSIndexSet indexSetWithIndex:section]];
|
| - }
|
| -}
|
| -
|
| -- (void)removeCardSection {
|
| - if (![self.collectionViewModel
|
| - hasSectionForSectionIdentifier:SectionIdentifierCards]) {
|
| - return;
|
| - }
|
| - NSInteger section = [self.collectionViewModel
|
| - sectionForSectionIdentifier:SectionIdentifierCards];
|
| - [self.collectionViewModel removeSectionWithIdentifier:SectionIdentifierCards];
|
| - [self.collectionView deleteSections:[NSIndexSet indexSetWithIndex:section]];
|
| -}
|
| -
|
| #pragma mark - MDCCollectionViewStylingDelegate
|
|
|
| - (CGFloat)collectionView:(UICollectionView*)collectionView
|
|
|