@@ -103,96 +103,12 @@ import BraintreeCore
103
103
return creditCardBody
104
104
}
105
105
106
- func graphQLParameters( ) -> CreditCardGraphQLBody {
107
- return CreditCardGraphQLBody (
108
- card: self ,
109
- shouldValidate: shouldValidate,
110
- authenticationInsightRequested: authenticationInsightRequested,
111
- merchantAccountID: merchantAccountID
112
- )
113
- }
114
-
115
- // MARK: - Private Methods
116
-
117
- // private func buildCardDictionary(isGraphQL: Bool) -> [String: Any] {
118
- // var cardDictionary: [String: Any] = [:]
119
- //
120
- // if let number {
121
- // cardDictionary["number"] = number
122
- // }
123
- //
124
- // if let expirationMonth {
125
- // cardDictionary[isGraphQL ? "expirationMonth" : "expiration_month"] = expirationMonth
126
- // }
127
- //
128
- // if let expirationYear {
129
- // cardDictionary[isGraphQL ? "expirationYear" : "expiration_year"] = expirationYear
130
- // }
131
- //
132
- // if let cvv {
133
- // cardDictionary["cvv"] = cvv
134
- // }
135
- //
136
- // if let cardholderName {
137
- // cardDictionary[isGraphQL ? "cardholderName" : "cardholder_name"] = cardholderName
138
- // }
139
- //
140
- // return cardDictionary
141
- // }
142
-
143
- // swiftlint:disable cyclomatic_complexity
144
- // private func buildBillingAddressDictionary(isGraphQL: Bool) -> [String: String] {
145
- // var billingAddressDictionary: [String: String] = [:]
146
- //
147
- // if let firstName {
148
- // billingAddressDictionary[isGraphQL ? "firstName" : "first_name"] = firstName
149
- // }
150
- //
151
- // if let lastName {
152
- // billingAddressDictionary[isGraphQL ? "lastName" : "last_name"] = lastName
153
- // }
154
- //
155
- // if let company {
156
- // billingAddressDictionary["company"] = company
157
- // }
158
- //
159
- // if let postalCode {
160
- // billingAddressDictionary[isGraphQL ? "postalCode" : "postal_code"] = postalCode
161
- // }
162
- //
163
- // if let streetAddress {
164
- // billingAddressDictionary[isGraphQL ? "streetAddress" : "street_address"] = streetAddress
165
- // }
166
- //
167
- // if let extendedAddress {
168
- // billingAddressDictionary[isGraphQL ? "extendedAddress" : "extended_address"] = extendedAddress
169
- // }
170
- //
171
- // if let locality {
172
- // billingAddressDictionary["locality"] = locality
173
- // }
174
- //
175
- // if let region {
176
- // billingAddressDictionary["region"] = region
177
- // }
178
- //
179
- // if let countryName {
180
- // billingAddressDictionary[isGraphQL ? "countryName" : "country_name"] = countryName
181
- // }
182
- //
183
- // if let countryCodeAlpha2 {
184
- // billingAddressDictionary[isGraphQL ? "countryCodeAlpha2" : "country_code_alpha2"] = countryCodeAlpha2
185
- // }
186
- //
187
- // if let countryCodeAlpha3 {
188
- // billingAddressDictionary[isGraphQL ? "countryCode" : "country_code_alpha3"] = countryCodeAlpha3
189
- // }
190
- //
191
- // if let countryCodeNumeric {
192
- // billingAddressDictionary[isGraphQL ? "countryCodeNumeric" : "country_code_numeric"] = countryCodeNumeric
193
- // }
194
- //
195
- // return billingAddressDictionary
196
- // }
197
- // swiftlint:enable cyclomatic_complexity
106
+ func graphQLParameters( ) -> CreditCardGraphQLBody {
107
+ return CreditCardGraphQLBody (
108
+ card: self ,
109
+ shouldValidate: shouldValidate,
110
+ authenticationInsightRequested: authenticationInsightRequested,
111
+ merchantAccountID: merchantAccountID
112
+ )
113
+ }
198
114
}
0 commit comments