  //
- //  PaymentVaultViewController.swift
- //  MercadoPagoSDK
- //
- //  Created by Maria cristina rodriguez on 15/1/16.
- //  Copyright © 2016 MercadoPago. All rights reserved.
- //
- import UIKit
- fileprivate func < <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
-    switch (lhs, rhs) {
-    case let (l?, r?):
-        return l < r
-    case (nil, _?):
-        return true
-    default:
-        return false
-    }
- }
- 
- fileprivate func > <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
-    switch (lhs, rhs) {
-    case let (l?, r?):
-        return l > r
-    default:
-        return rhs < lhs
-    }
- }
- 
- 
- open class PaymentVaultViewController: MercadoPagoUIViewController, UICollectionViewDataSource, UICollectionViewDelegate, UICollectionViewDelegateFlowLayout{
+//  PaymentVaultViewController.swift
+//  MercadoPagoSDK
+//
+//  Created by Maria cristina rodriguez on 15/1/16.
+//  Copyright © 2016 MercadoPago. All rights reserved.
+//
+
+import UIKit
+fileprivate func < <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
+  switch (lhs, rhs) {
+  case let (l?, r?):
+    return l < r
+  case (nil, _?):
+    return true
+  default:
+    return false
+  }
+}
+
+fileprivate func > <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
+  switch (lhs, rhs) {
+  case let (l?, r?):
+    return l > r
+  default:
+    return rhs < lhs
+  }
+}
+
+
+open class PaymentVaultViewController: MercadoPagoUIViewController, UICollectionViewDataSource, UICollectionViewDelegate, UICollectionViewDelegateFlowLayout{
     
     @IBOutlet weak var collectionSearch: UICollectionView!
-    
+
     
     static let VIEW_CONTROLLER_NIB_NAME : String = "PaymentVaultViewController"
     

    }
    
    fileprivate func getCustomerCards(){
        
        if self.viewModel!.shouldGetCustomerCardsInfo() {
            self.showLoading()
            MerchantServer.getCustomer({ (customer: Customer) -> Void in

        
    }
    
   

    public func numberOfSections(in collectionView: UICollectionView) -> Int {
        if (self.viewModel.getCustomerPaymentMethodsToDisplayCount() > 0){
            return 2
        }else{
            return 1
        }

    }

    public func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
        
        switch (indexPath as NSIndexPath).section {
        
        case defaultsPaymentMethodsSection():
            let paymentSearchItemSelected = self.viewModel.currentPaymentMethodSearch[(indexPath as NSIndexPath).row]
            collectionView.deselectItem(at: indexPath, animated: true)
