[accelerator] fix cashapp acceleration on mobile

This commit is contained in:
nymkappa 2024-07-21 23:07:55 +02:00
parent 08d3beed72
commit 09b09710e4
No known key found for this signature in database
GPG Key ID: 92358FC85D9645DE

View File

@ -429,7 +429,8 @@ export class AccelerateCheckout implements OnInit, OnDestroy {
try {
//@ts-ignore
this.payments = window.Square.payments(this.square.appId, this.square.locationId)
if (this._step === 'cashapp') {
const urlParams = new URLSearchParams(window.location.search);
if (this._step === 'cashapp' || urlParams.get('cash_request_id')) {
await this.requestCashAppPayment();
} else if (this._step === 'applepay') {
await this.requestApplePayPayment();