mirror of
https://github.com/bitwarden/browser
synced 2025-12-21 10:43:35 +00:00
Collect tax info for payments
This commit is contained in:
@@ -166,7 +166,7 @@ export class PaymentComponent implements OnInit {
|
||||
} else if (this.method === PaymentMethodType.Card || this.method === PaymentMethodType.BankAccount) {
|
||||
if (this.method === PaymentMethodType.Card) {
|
||||
this.apiService.postSetupPayment().then((clientSecret) =>
|
||||
this.stripe.confirmCardSetup(clientSecret, this.stripeCardNumberElement))
|
||||
this.stripe.handleCardSetup(clientSecret, this.stripeCardNumberElement))
|
||||
.then((result: any) => {
|
||||
if (result.error) {
|
||||
reject(result.error.message);
|
||||
@@ -198,8 +198,8 @@ export class PaymentComponent implements OnInit {
|
||||
return;
|
||||
}
|
||||
const handleCardPayment = () => this.showMethods ?
|
||||
this.stripe.confirmCardPayment(clientSecret, this.stripeCardNumberElement) :
|
||||
this.stripe.confirmCardPayment(clientSecret);
|
||||
this.stripe.handleCardSetup(clientSecret, this.stripeCardNumberElement) :
|
||||
this.stripe.handleCardSetup(clientSecret);
|
||||
return handleCardPayment().then(async (result: any) => {
|
||||
if (result.error) {
|
||||
reject(result.error.message);
|
||||
|
||||
Reference in New Issue
Block a user